File: types_test.go

package info (click to toggle)
golang-github-pzhin-go-sophia 0.0~git20180715.8bdc218-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 924 kB
  • sloc: ansic: 23,001; makefile: 4
file content (21 lines) | stat: -rw-r--r-- 366 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package sophia

import (
	"testing"

	"github.com/stretchr/testify/require"
)

func TestUnknownFieldType(t *testing.T) {
	typ := FieldType(len(fieldTypeNames))
	require.Panics(t, func() {
		_ = typ.String()
	})
}

func TestUnknownCompressionType(t *testing.T) {
	typ := CompressionType(len(compressionTypeNames))
	require.Panics(t, func() {
		_ = typ.String()
	})
}