Skip to content

Commit

Permalink
consensus test enable election test by default
Browse files Browse the repository at this point in the history
  • Loading branch information
vanessaviolet committed Jul 7, 2023
1 parent 48ed1c7 commit 7b6ad77
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/mixin-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ jobs:
if: ${{ matrix.os == 'ubuntu-latest' }}
working-directory: .
run: |
INPUT=10 go test ./... -v
ELECTION=false INPUT=10 go test ./... -v
5 changes: 4 additions & 1 deletion rpc/consensus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ func testConsensus(t *testing.T, snapVersionMint int) {
kernel.TestMockReset()

level, _ := strconv.ParseInt(os.Getenv("LOG"), 10, 64)
enableElection, _ := strconv.ParseBool(os.Getenv("ELECTION"))
enableElection, err := strconv.ParseBool(os.Getenv("ELECTION"))
if err != nil {
enableElection = true
}
inputs, _ := strconv.ParseInt(os.Getenv("INPUT"), 10, 64)
logger.SetLevel(int(level))
if inputs > 0 {
Expand Down

0 comments on commit 7b6ad77

Please sign in to comment.