container/dispatcher: check simple test errors via reflect

Again, avoids the errors package concealing unexpected behaviours.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2025-08-29 22:12:21 +09:00
parent 50972096cd
commit d7c7c69a13
2 changed files with 3 additions and 3 deletions

View File

@@ -115,7 +115,7 @@ func checkSimple(t *testing.T, fname string, testCases []simpleTestCase) {
t.Run(tc.name, func(t *testing.T) {
defer handleExitStub()
k := &kstub{t: t, want: tc.want, wg: new(sync.WaitGroup)}
if err := tc.f(k); !errors.Is(err, tc.wantErr) {
if err := tc.f(k); !reflect.DeepEqual(err, tc.wantErr) {
t.Errorf("%s: error = %v, want %v", fname, err, tc.wantErr)
}
k.handleIncomplete(func(k *kstub) {