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

Feature/dei 24 tests for parser #7

Merged
merged 7 commits into from
Feb 10, 2023

Conversation

CindyvdVries
Copy link
Collaborator

No description provided.

Copy link
Contributor

@HiddeElzinga HiddeElzinga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review ok, but maybe have a look at the comments

IModelData: _description_
"""
"""Parse the Yaml input file into a data object"""
print('contennts', contents)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

print statement can be removed

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to add a description for the parameter ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check, added it. Have now on multiple locations a default for the description.
print statement removed


# Assert
expected_message = "Missing element multipliers"
assert exception_raised.args[0] == expected_message
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we also want a test for invalid data in the multipliers -> like "multipliers": "abc", or "multipliers": [0.0, "abc"]
Do we need to check for duplicate keys ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dict can never have duplicate keys, so this will never occurs. When yaml is loaded this already filtered out. Don't think we need to check that.

Added a Valueerror when the multipliers are not a list of floats.

@CindyvdVries CindyvdVries merged commit b616a0d into main Feb 10, 2023
@CindyvdVries CindyvdVries deleted the feature/DEI-24-tests-for-parser branch February 10, 2023 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants