Skip to content

Commit

Permalink
Test: Add tests for functions in helpers.cairo (#208)
Browse files Browse the repository at this point in the history
* test: add tests for helper functions

* refactor: use game_id via params
  • Loading branch information
Jagadeeshftw authored Feb 10, 2025
1 parent c0a4e5f commit 5c89f9f
Show file tree
Hide file tree
Showing 2 changed files with 454 additions and 4 deletions.
1 change: 0 additions & 1 deletion onchain/src/systems/game_actions.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -689,7 +689,6 @@ pub mod GameActions {

fn get_active_colors(self: @ContractState, game_id: u64) -> Array<u8> {
let mut world = self.world_default();
let game_id = self.get_current_game_id();
let game: Game = world.read_model(game_id);
let mut colors: Array<u8> = ArrayTrait::new();
if game.player_red != 0 {
Expand Down
Loading

0 comments on commit 5c89f9f

Please sign in to comment.