NatLabRockies / NatLabRockies/H2Integrate
Update controller tests to not depend on `calculate_combined_outputs` function
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 26
- Forks
- 44
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 16
Description
Update the control tests to test different outputs (don't test the unmet demand, excess commodity, etc). Some control tests have many subtests on outputs that are now calculated in demand components, so a function calculate_combined_outputs was added to calculate these outputs. Tests that use calculate_combined_outputs should be updated to test other outputs from storage performance models or the controllers, not test outputs from the demand components.
This came up in PR #666
Originally posted by @elenya-grant in https://github.com/NatLabRockies/H2Integrate/pull/666#discussion_r3081032323
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the control tests and PR #666 discussion to find cases that call calculate_combined_outputs. Replace assertions on unmet demand, excess commodity, and other demand-component outputs with assertions on outputs from storage performance models or controllers. Done means those tests no longer depend on calculate_combined_outputs while still checking the relevant control behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100