-
Notifications
You must be signed in to change notification settings - Fork 57
ignore excluded paths when transferring files #163
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 3 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -230,3 +230,34 @@ func TestHandshakeTimeout(t *testing.T) { | |
| t.Fatalf("Expected handshake timeout, got: %s", err) | ||
| } | ||
| } | ||
|
|
||
| func TestIsExclude(t *testing.T) { | ||
| testCases := []struct { | ||
| Exclude []string | ||
| Path string | ||
| Is bool | ||
|
||
| }{ | ||
| { | ||
| Exclude: []string{"foo"}, | ||
| Path: "foo", | ||
| Is: true, | ||
| }, | ||
| { | ||
| Exclude: []string{"foo/*"}, | ||
| Path: "foo/bar", | ||
| Is: true, | ||
| }, | ||
| { | ||
| Exclude: []string{"foo"}, | ||
| Path: "bar", | ||
| Is: false, | ||
| }, | ||
| } | ||
|
|
||
| for _, tc := range testCases { | ||
| if isExcluded(tc.Path, tc.Exclude) != tc.Is { | ||
| t.Fatalf("Expected %s to be excluded: %t", tc.Path, tc.Is) | ||
| } | ||
| } | ||
|
|
||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.