-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add logging_tests command w/o error collection
- Loading branch information
1 parent
1623489
commit fc377b5
Showing
5 changed files
with
40 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import os | ||
|
||
from lib.runner import run_module, file_to_module | ||
|
||
LOGGING_TESTS_DIR = 'logging_tests' | ||
|
||
def all_logging_test_files(): | ||
tests = [] | ||
for root, dirs, files in os.walk(LOGGING_TESTS_DIR): | ||
tests.extend([f'{root}/{f}' for f in files if f.endswith('.py')]) | ||
|
||
return tests | ||
|
||
|
||
def run_logging_tests(client): | ||
# print client, then call run_module for each test. collect all failures and print them at the end | ||
print(client) | ||
for file in all_logging_test_files(): | ||
# TODO: collect failure | ||
run_module(file_to_module(file), {}) | ||
|
||
# TODO: print out all failures + logs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,2 @@ | ||
import trio | ||
from pyrum import SubprocessConn, Rumor | ||
|
||
from .utils import * | ||
|
||
@with_rumor | ||
async def run(rumor, args): | ||
async def run(args): | ||
return 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,2 @@ | ||
import trio | ||
from pyrum import SubprocessConn, Rumor | ||
|
||
from .utils import with_rumor | ||
|
||
@with_rumor | ||
async def run(rumor, args): | ||
async def run(args): | ||
return 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters