-
Notifications
You must be signed in to change notification settings - Fork 235
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
Initial backend for Next Gen #426
Conversation
🎉 Thanks @BeyondEvil ! I'll take a look as soon as I can |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than these comments, LGTM! Thank you again @BeyondEvil !
@@ -0,0 +1,66 @@ | |||
import json | |||
from typing import Any |
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
data = json.dumps(data) | ||
|
||
with self._data_file.open("w", buffering=1, encoding="UTF-8") as f: | ||
f.write("const jsonData = ") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we combine these f.write
calls on an f string line f"const jsonData = {data}\n"
?
f.write("\n") | ||
|
||
@pytest.hookimpl(trylast=True) | ||
def pytest_sessionstart(self, session): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't all the self._write
calls overwrite self._data_file
?
The initial backend, implemented alongside the "legacy" report.
It will create a JSON file with the title, environment (from metadata) and all tests.
Any calculations, summary of passed/failed, durations etc. will be left to the frontend.
extras
andhooks
are not implemented yet.I know why the tests are failing, will fix tomorrow.