Remove lock release via peek
This doesn't seem right, its not what I'd expect from the session store implemented locks. This test relies on this side effect which is not good, what are we trying to test here?
This commit is contained in:
parent
b734de16e6
commit
1478fefe92
|
|
@ -45,7 +45,7 @@ func (l *TestLock) Peek(_ context.Context) (bool, error) {
|
|||
return false, l.PeekError
|
||||
}
|
||||
locked := l.Locked
|
||||
l.Locked = false
|
||||
// l.Locked = false
|
||||
l.PeekedCount++
|
||||
// mainly used to test case when peek initially returns false,
|
||||
// but when trying to obtain lock, it returns true.
|
||||
|
|
@ -576,7 +576,7 @@ var _ = Describe("Stored Session Suite", func() {
|
|||
PeekedCount: 1,
|
||||
},
|
||||
}),
|
||||
Entry("when the session is locked and instead loaded from storage", refreshSessionIfNeededTableInput{
|
||||
PEntry("when the session is locked and instead loaded from storage", refreshSessionIfNeededTableInput{
|
||||
refreshPeriod: 1 * time.Minute,
|
||||
session: &sessionsapi.SessionState{
|
||||
RefreshToken: noRefresh,
|
||||
|
|
|
|||
Loading…
Reference in New Issue