add zip and parity stuff

This commit is contained in:
2023-07-18 18:21:12 -06:00
parent 8abb1408f0
commit f260ee1c9f
11 changed files with 403 additions and 21 deletions

36
fileUtilities/zip_test.go Normal file
View File

@ -0,0 +1,36 @@
package fileUtilities
import "testing"
func Test_replaceBackslashes(t *testing.T) {
type args struct {
input string
}
tests := []struct {
name string
args args
want string
}{
{
name: "replace backslashes",
args: args{
input: "C:\\Users\\james\\Documents\\test",
},
want: "C:/Users/james/Documents/test",
},
{
name: "no backslashes",
args: args{
input: "C:/Users/james/Documents/test",
},
want: "C:/Users/james/Documents/test",
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := replaceBackslashes(tt.args.input); got != tt.want {
t.Errorf("replaceBackslashes() = %v, want %v", got, tt.want)
}
})
}
}