MCPcopy
hub / github.com/MetaCubeX/mihomo / assertLenEqual

Function assertLenEqual

common/orderedmap/utils_test.go:53–60  ·  view source on GitHub ↗
(t *testing.T, orderedMap *OrderedMap[K, V], expectedLen int)

Source from the content-addressed store, hash-verified

51}
52
53func assertLenEqual[K comparable, V any](t *testing.T, orderedMap *OrderedMap[K, V], expectedLen int) {
54 t.Helper()
55
56 assert.Equal(t, expectedLen, orderedMap.Len())
57
58 // also check the list length, for good measure
59 assert.Equal(t, expectedLen, orderedMap.list.Len())
60}
61
62func randomHexString(t *testing.T, length int) string {
63 t.Helper()

Callers 4

TestUnmarshallYAMLFunction · 0.85
TestUnmarshallJSONFunction · 0.85
TestBasicFeaturesFunction · 0.85
TestEmptyMapOperationsFunction · 0.85

Calls 2

EqualMethod · 0.65
LenMethod · 0.65

Tested by

no test coverage detected