diff --git a/container/mts/encoder_test.go b/container/mts/encoder_test.go index 24fb823d..4443e8e8 100644 --- a/container/mts/encoder_test.go +++ b/container/mts/encoder_test.go @@ -197,7 +197,7 @@ func TestEncodePcm(t *testing.T) { for i+PacketSize <= len(clip) { // Check MTS packet - if !(pkt.PID() == audioPid) { + if !(pkt.PID() == AudioPid) { i += PacketSize if i+PacketSize <= len(clip) { copy(pkt[:], clip[i:i+PacketSize]) diff --git a/container/mts/mpegts_test.go b/container/mts/mpegts_test.go index 4c90cc0e..511a9eb1 100644 --- a/container/mts/mpegts_test.go +++ b/container/mts/mpegts_test.go @@ -79,7 +79,7 @@ func TestGetPTSRange(t *testing.T) { curTime += interval } - got, err := GetPTSRange(clip.Bytes(), videoPid) + got, err := GetPTSRange(clip.Bytes(), VideoPid) if err != nil { t.Fatalf("did not expect error getting PTS range: %v", err) } @@ -139,7 +139,7 @@ func writeFrame(b *bytes.Buffer, frame []byte, pts uint64) error { for len(buf) != 0 { pkt := Packet{ PUSI: pusi, - PID: videoPid, + PID: VideoPid, RAI: pusi, CC: 0, AFC: hasAdaptationField | hasPayload,