Commit Graph

32 Commits

Author SHA1 Message Date
Philipp Wolfer
67dc990230 Speed up test_pipe_protocol test
Only test a single message, reduce timeouts.
2023-08-20 15:38:31 +02:00
Philipp Wolfer
165cc8519d Add small delays in test_pipe_protocol tests 2023-08-16 16:55:34 +02:00
Philipp Wolfer
df81f4e48a Make pipe tests more robust on error 2023-08-15 14:25:34 +02:00
Philipp Wolfer
38ea9d5902 Simplified pipe test case, fixes tests on Windows 2023-08-14 18:44:06 +02:00
Philipp Wolfer
ad97e5bf7d PICARD-2544: Use UUID for pipes in tests 2022-09-13 07:56:42 +02:00
skelly37
1dcf5faf98 included new functionality in our test cases + re-run github actions 2022-07-21 12:53:17 +02:00
skelly37
b6e98ae2cf added missing test 2022-07-20 11:31:13 +02:00
skelly37
e5b35cd4aa tests added 2022-07-20 10:27:09 +02:00
skelly37
bc295688ef maybe arbitrary timeout was bad, also loop sending the same things should be replaced with longer to_send if needed 2022-06-28 12:51:50 +02:00
skelly37
d0f26d0bce removed logger from tests 2022-06-28 11:38:10 +02:00
skelly37
152f176ecc switched from set to tuple in test case
since set was already problematic, leaving this might solve the latest-macos 3.7 issue. the problem is with python itself, not with the pipe protocol what i've proven, so it's safe to do sth like this imo
2022-06-28 11:02:59 +02:00
skelly37
cb993bdcff simplified test reader 2022-06-27 10:26:22 +02:00
skelly37
7c8b1606c1 zas's suggestions 2022-06-27 10:13:54 +02:00
skelly37
22a6d708bc tests fixed, better logging, minor refactoring
I've simplified the code for tagger's pipe server, i've added better logging for pipe, I've replaced dicts with strings to fix python's problems with the tests. Pipe works fine, the problem seems deeper than we thought, this approach also tests the pipe correctly.
2022-06-26 19:14:02 +02:00
skelly37
4693adbce6 BrokenPipeError handled, logs in test cases
All the issues with Unix tests was caused by the BrokenPipeError which is actually hard to reproduce. I've added a basic handle procedure: re-create the pipe and log a warning.
Should work now, and if not, we at least have more verbose logging system
2022-06-25 18:08:32 +02:00
skelly37
8099f31da3 timeout for writer in tests included 2022-06-24 13:25:57 +02:00
skelly37
9af8002b16 retry tests 20 times, maybe it will help with stucks 2022-06-24 08:05:52 +02:00
skelly37
82585445ae windows pipe improved 2022-06-23 15:18:18 +02:00
skelly37
cb714d7cf6 timeout included 2022-06-22 19:52:59 +02:00
skelly37
fb2cb75d92 fixed commit 2022-06-21 18:14:51 +02:00
skelly37
c0c5074297 my last idea 2022-06-21 10:22:25 +02:00
skelly37
46c88fb567 fallback used, filename tests removed, should work fine
I've decided to remove the filename tests becaue they provide no useful value during the tests. Everything has to be mocked and so on... Debug-logging the pipe path should do, because during the tests we cannot be 100% sure that the specific folder will be writable, the env variable will be declared etc.
2022-06-21 08:44:28 +02:00
skelly37
8b30c2e858 missed call 2022-06-16 11:31:43 +02:00
skelly37
b83ce3f2d8 NoneType guard, defaulting to /tmp 2022-06-16 11:29:15 +02:00
skelly37
2de7543f31 added mocking for filename generation tests 2022-06-16 11:02:51 +02:00
skelly37
5f27781635 os-specific filename tests with decorators 2022-06-15 21:13:40 +02:00
skelly37
d029a9d824 better logger, tuple split into lines 2022-06-15 08:54:43 +02:00
skelly37
83bbdb3e18 fallback path generates warn, tests descriped where appliable, path is tested 2022-06-14 19:34:27 +02:00
skelly37
6782ddf0c5 suggestions included, minor refactor 2022-06-14 18:56:58 +02:00
skelly37
aa8233bf1d codacy 2022-06-14 17:49:49 +02:00
skelly37
f66e47b5a0 pipe reads&sends lists now, the whole protocol is tested 2022-06-14 17:42:08 +02:00
skelly37
904824e3dc started writing test cases, app_name and app_version in pipe are forced to be str 2022-06-13 11:19:32 +02:00