Skip to content
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

Tests #27

Merged
merged 2 commits into from
Oct 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ public class Tests {
clipboardData.Add("Text", new MemoryStream(bytes));

await client.SendData(clipboardData);
await Task.Delay(3000);
await server.Stop();
client.Stop();

Expand Down Expand Up @@ -145,6 +146,7 @@ public class Tests {

} finally {
Directory.Delete(testsPath, true);
await Task.Delay(1000);
await server.Stop();
client.Stop();
}
Expand Down Expand Up @@ -202,6 +204,7 @@ public class Tests {
await client.SendFileDropList(files);
} finally {
Directory.Delete(testsPath, true);
await Task.Delay(3000);
await server.Stop();
client.Stop();
}
Expand Down Expand Up @@ -275,6 +278,7 @@ public class Tests {
await client.SendFileDropList(files);
} finally {
Directory.Delete(testsPath, true);
await Task.Delay(1000);
await server.Stop();
client.Stop();
}
Expand Down Expand Up @@ -360,6 +364,7 @@ public class Tests {
await client.SendFileDropList(files);
} finally {
Directory.Delete(testsPath, true);
await Task.Delay(500);
await server.Stop();
client.Stop();
}
Expand Down
10 changes: 0 additions & 10 deletions ShareClipbrd/ShareClipbrd.Core/Services/DataClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,6 @@ IAddressDiscoveryService addressDiscoveryService

public async Task SendFileDropList(StringCollection fileDropList) {
cts.Cancel();
// var inProcess = !pingTimer.Enabled;
// if(inProcess) {
// Debug.WriteLine("--- inProcess 0");
// await Task.Delay(1000);
// }
cts = new();
var cancellationToken = cts.Token;
try {
Expand Down Expand Up @@ -119,11 +114,6 @@ IAddressDiscoveryService addressDiscoveryService

public async Task SendData(ClipboardData clipboardData) {
cts.Cancel();
// var inProcess = !pingTimer.Enabled;
// if(inProcess) {
// Debug.WriteLine("--- inProcess 0");
// await Task.Delay(1000);
// }
cts = new();
var cancellationToken = cts.Token;
try {
Expand Down