Skip to content

tests: characterize inverter baseclass battery math#333

Merged
MaStr merged 1 commit intoMaStr:mainfrom
filiplajszczak:inverter-baseclass-battery-math
Apr 15, 2026
Merged

tests: characterize inverter baseclass battery math#333
MaStr merged 1 commit intoMaStr:mainfrom
filiplajszczak:inverter-baseclass-battery-math

Conversation

@filiplajszczak
Copy link
Copy Markdown
Contributor

This adds characterization tests for the shared battery-capacity math in InverterBaseclass, covering stored energy, usable energy, max capacity, usable capacity, and current free-capacity behavior above max_soc.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds targeted characterization tests for the shared battery capacity/energy math implemented in InverterBaseclass, ensuring the current SOC-based calculations remain stable across refactors.

Changes:

  • Introduces a FakeInverter test double to exercise InverterBaseclass math in isolation.
  • Adds unit tests covering stored energy, stored usable energy, max capacity, usable capacity, and free capacity behavior above max_soc.

@MaStr MaStr merged commit bd4f80c into MaStr:main Apr 15, 2026
14 checks passed
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.

3 participants