Skip to content

Commit 9ff0fe9

Browse files
committed
Rename test and change test order
1 parent 726ba64 commit 9ff0fe9

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

‎token_store_test.go‎

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -108,16 +108,6 @@ func TestFromJSONInvalid(t *testing.T) {
108108
}
109109
}
110110

111-
func TestFromStringSingleToken(t *testing.T) {
112-
ts := NewTokenStoreFromString("token-1")
113-
114-
want := 1
115-
got := len(ts.Entries)
116-
if diff := cmp.Diff(want, got); diff != "" {
117-
t.Errorf("mismatch (-want +got): %s", diff)
118-
}
119-
}
120-
121111
func TestEncodingIsCompatible(t *testing.T) {
122112
// Check that the implementation we are using is compatible with other implementations,
123113
// that is, base64-url-encoding with no padding.
@@ -138,6 +128,16 @@ func TestEncodingIsCompatible(t *testing.T) {
138128
}
139129
}
140130

131+
func TestFromStringV1SingleToken(t *testing.T) {
132+
ts := NewTokenStoreFromString("token-1")
133+
134+
want := 1
135+
got := len(ts.Entries)
136+
if diff := cmp.Diff(want, got); diff != "" {
137+
t.Errorf("mismatch (-want +got): %s", diff)
138+
}
139+
}
140+
141141
func TestFromStringV2SingleToken(t *testing.T) {
142142
json := `{"entries":[{"token":"token-1","added_at":1712664900}]}`
143143
encoded := V2EncodeString([]byte(json))

0 commit comments

Comments
 (0)