Skip to content

Commit d3cf611

Browse files
committed
common: test DemoHeader.FrameTime with PlaybackTime=0
1 parent 4ac8a60 commit d3cf611

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

common/common_test.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import (
44
"testing"
55
"time"
66

7-
r3 "github.com/golang/geo/r3"
8-
assert "github.com/stretchr/testify/assert"
7+
"github.com/golang/geo/r3"
8+
"github.com/stretchr/testify/assert"
99
)
1010

1111
func TestBombPosition(t *testing.T) {
@@ -39,6 +39,10 @@ func TestDemoHeader(t *testing.T) {
3939
assert.Equal(t, time.Second/128, header.TickTime(), "TickTime should be 1/128")
4040
}
4141

42+
func TestDemoHeader_FrameTime_PlaybackFrames_Zero(t *testing.T) {
43+
assert.Zero(t, DemoHeader{}.FrameTime())
44+
}
45+
4246
func TestTeamState(t *testing.T) {
4347
assert.Equal(t, TeamTerrorists, NewTeamState(TeamTerrorists).Team())
4448
assert.Equal(t, TeamCounterTerrorists, NewTeamState(TeamCounterTerrorists).Team())

0 commit comments

Comments
 (0)