mirror of
https://github.com/aler9/gortsplib
synced 2025-10-04 06:46:42 +08:00
improve coverage (#168)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package h264
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
@@ -125,6 +126,11 @@ func TestAnnexBUnmarshalError(t *testing.T) {
|
||||
[]byte{0x00, 0x00, 0x01, 0xaa, 0x00, 0x00, 0x01},
|
||||
"empty NALU",
|
||||
},
|
||||
{
|
||||
"too many nalus",
|
||||
bytes.Repeat([]byte{0x00, 0x00, 0x01, 0x0a}, 21),
|
||||
"NALU count (21) exceeds maximum allowed (20)",
|
||||
},
|
||||
} {
|
||||
t.Run(ca.name, func(t *testing.T) {
|
||||
_, err := AnnexBUnmarshal(ca.enc)
|
||||
|
Reference in New Issue
Block a user