Skip to content

Add unit tests for the season PoC model and functions #90

@coxmars

Description

@coxmars

Start this issue once we have merged the model and functions implemented in the season: #89

You can review the current tests and try to add edge cases as a plus.

  • Invalid inputs (e.g., non-existent IDs, overlapping dates).
  • Handling of empty dynamic arrays like active_players.

However, the idea/scope for this task is to implement the system/flow tests for the functions created.

  • Use this PR as an example of what we want to have: Add tests for tournament_system #101
  • So, you need to create a new file like season.cairo in systems directory.
  • Add the flow according with the functions and logic in season.cairo and after that validate all it's working as expected running sozo build/sozo test.
  • When it's done add the proof/output of those commands as an image in your PR.

Follow the Contributions Guidelines and PR guidelines/example etc.
Include clear comments to explain the test logic and why specific scenarios are covered.

If you need help just ask me here in a comment or ping me on Telegram in the group channel for external contributors.

Thanks for your time, please send a comment with your approach/solution, be creative and use a technical explanation and avoid ChatGPT or AI comments.

Metadata

Metadata

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions