Skip to content

Commit

Permalink
Add unknown environment test for GetInt
Browse files Browse the repository at this point in the history
  • Loading branch information
Edznux committed Oct 25, 2018
1 parent b00b4a7 commit ac37354
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions session/environment_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,10 @@ func TestSessionEnvironmentGetInt(t *testing.T) {
} else if i != 1234 {
t.Fatalf("unexpected integer: %d", i)
}

if err, _ := env.GetInt("unknownint"); err == nil {
t.Fatalf("expected error (unknown key): %v", err)
}
}

func TestSessionEnvironmentSorted(t *testing.T) {
Expand Down

0 comments on commit ac37354

Please sign in to comment.