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

TST: test_kda.py recommendations #3

Closed
9 tasks done
nawtrey opened this issue May 27, 2020 · 2 comments
Closed
9 tasks done

TST: test_kda.py recommendations #3

nawtrey opened this issue May 27, 2020 · 2 comments
Labels
testing Testing/verification related improvements/bugs

Comments

@nawtrey
Copy link
Collaborator

nawtrey commented May 27, 2020

This issue was originally opened in GitLab and used to track testing ideas. I've consolidated them into a single list below, but future testing ideas will have their own issues.

Testing ideas:

  • Add tests that sum probabilities and check if almost equal to 1
  • Check if all generated flux diagrams contain only 1 cycle -- redundant
  • For existing tests, add matrix method verification via kda.solve_matrix()
  • Add tests that count numbers of partial and directional partial diagrams
  • Add test for kda.calculate_pi_difference() to verify the fix for issue kda.calculate_pi_difference(), kda.calculate_thermo_force() are not generating the appropriate functional forms #15
  • Add regression test that counts the number of flux diagrams generated for multiple models. This is already halfway implemented, but needs to be expanded to include more known cases
  • Add additional unit tests for calculations.calc_thermo_force() (similar to test_thermo_force_4WL) where each test verifies the output of multiple models (4-state, 5-state).
  • Add unit tests for calculations.calculate_pi_difference() where each test verifies the output of multiple models (4-state, 4-state with leakage, 5-state)
    Add assertion to test_flux_diagram_counts verifying each flux diagram contains only 1 unique cycle
  • Add assertion to test_diagram_counts verifying the list of edges for each partial and directional diagram contains all nodes in the input diagram
@nawtrey nawtrey added the enhancement New feature or request label Jun 30, 2020
nawtrey added a commit that referenced this issue May 7, 2021
* Contributes to #3

* Replaces parametrized state probability tests to use `hypothesis` to
generate random values in a closed interval

* Adds probability sum checks (normalized to 1)

* Adds tests that verify the quantities of partial and directional
partial diagrams that are generated

* Increases code coverage of various errors across the code base
nawtrey added a commit that referenced this issue May 7, 2021
* Contributes to #3

* Replaces parametrized state probability tests to use `hypothesis` to
generate random values in a closed interval

* Adds probability sum checks (normalized to 1)

* Adds tests that verify the quantities of partial and directional
partial diagrams that are generated

* Increases code coverage of various errors across the code base
@nawtrey nawtrey changed the title test_KDA.py TST: test_kda.py recommendations Dec 6, 2021
@nawtrey nawtrey added testing Testing/verification related improvements/bugs and removed enhancement New feature or request labels Dec 6, 2021
nawtrey added a commit that referenced this issue Feb 20, 2022
* Add test `test_flux_diagram_counts` which
checks the cycle and flux diagram counts for
several models with known flux diagram counts.
Most test cases are examples from T.L. Hill's
book "Free Energy Transduction and
Biochemical Cycle Kinetics".

* Contributest to issue #3
nawtrey added a commit that referenced this issue Feb 20, 2022
* Add test `test_flux_diagram_counts` which
checks the cycle and flux diagram counts for
several models with known flux diagram counts.
Most test cases are examples from T.L. Hill's
book "Free Energy Transduction and
Biochemical Cycle Kinetics".

* Contributes to issue #3
@nawtrey
Copy link
Collaborator Author

nawtrey commented Feb 20, 2022

With #59 merged I checked off the corresponding task.

nawtrey added a commit that referenced this issue Aug 10, 2024
* To address a task in #3, a new test,
`test_thermo_force_5WL` was added which
calculates the thermodynamic driving
force for the Hill 5-state model

* Fixes `test_thermo_force_4WL` assertion
to actually compare the output expression
with the expected expression
nawtrey added a commit that referenced this issue Aug 10, 2024
* Adds test `test_thermo_force_5WL` which
calculates the thermodynamic driving
force for the Hill 5-state model

* Fixes `test_thermo_force_4WL` assertion
to actually compare the output expression
with the expected expression

* Adds `test_calc_pi_difference_5WL` which
makes a numerical comparison to calculated
values using hypothesis and compares the exact
output expression for the Hill 5-state model

* Adds assertions for partial and directional diagrams
verifying that each generated diagram has the same
number of nodes as the input kinetic diagram

* Fixes issue #3
@nawtrey
Copy link
Collaborator Author

nawtrey commented Aug 10, 2024

Remaining tasks were addressed in a1e6658. Closing.

@nawtrey nawtrey closed this as completed Aug 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
testing Testing/verification related improvements/bugs
Projects
None yet
Development

No branches or pull requests

1 participant