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

Add comprehensive unit tests for TicTacToe and NestedArray contracts #37

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

pali101
Copy link
Contributor

@pali101 pali101 commented Oct 27, 2024

This PR introduces improved unit tests for the TicTacToe and NestedArray contracts:

  • TicTacToe Contract Tests

    • Tests for winning conditions in rows, columns, and diagonals for both 1s and 0s.
    • Tests with all 1s and all 0s to confirm both are treated as wins.
    • Mixed configurations with no winning lines to ensure correct detection of non-winning states.
    • Added cases with incomplete rows/columns and mixed values that should return false for isWinning.
  • NestedArray Contract Tests:

    • Includes tests for handling large numbers and nested structures.
    • Arrays with maximum and minimum values, including empty and fully populated arrays.

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.

1 participant