-
Notifications
You must be signed in to change notification settings - Fork 37
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
chore(test): Add config file option to e2e metal tooling #249
Conversation
63e8bf5
to
7f8500d
Compare
Codecov Report
@@ Coverage Diff @@
## main #249 +/- ##
===========================================
- Coverage 55.81% 40.29% -15.53%
===========================================
Files 44 46 +2
Lines 2012 2169 +157
===========================================
- Hits 1123 874 -249
- Misses 781 1236 +455
+ Partials 108 59 -49
Continue to review full report at Codecov.
|
ba5571e
to
a560674
Compare
3657b8a
to
3cb4762
Compare
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.
Standard python style is to use multiples of 4 spaces as indentation.
Even if it stays at 3 spaces, the indentation is not consistent, there are places where it's 4 spaces and there are places where it's 3 spaces. All can be auto-fixed with autoformat tools like autopep8
, yapf -i
or black
.
Other than that, some comments, but lgtm
lol i thought the spacing looked a bit different between files 😂 , but i didn;t want to do all that before review otherwise it would make the general pr diff huge. i will format them all right before merge |
ce559e5
to
fc798f0
Compare
A new instance of Config will be initialised with a set of default config. These are just the values I happened to be hardcoding before, and there was no special reason for any of them, but they work. Config can then be loaded from a file and validated against a schema. This config will then overwrite the appropriate values in the object config. Config can also be altered via flags. The 'final' config at that point can be validated. The validation is all a bit naive right now as I didn't want to get too into it.
The first step, simply loads the file and reads the config into the Test object. Generation of default flag values is now handled in the default config setup of the Config class.
Creation of userdata and default name values is handled in the Config class now.
Also create a handy help script for passing flags to the e2e tests
It was not working because I was using params from the wrong object. Needs to be on the metal.
fc798f0
to
aa5916e
Compare
Note: the last 2 commits are file formatting only and disguise other things which have happened
What this PR does / why we need it:
This PR adds a bit of nice UX to the e2e python tool.
Users can now pass a config file:
Which looks like this:
Each new instance of Config will be initialised with a set of default
config. These are just the values I happened to be hardcoding before,
and there was no special reason for any of them, but they work.
Config can then be loaded from a file and validated against a schema.
This config will then overwrite the appropriate values in the object
config.
Config can also be altered via flags. The 'final' config at that point
can be validated.
The validation is all a bit naive right now as I didn't want to get too
into it.
Not all device config options exist yet, but it is fairly trivial to add as
needed later.
Special notes for your reviewer:
Checklist: