MCPcopy Create free account
hub / github.com/ReactiveX/RxGo / Test_Observable_Distinct_Error

Function Test_Observable_Distinct_Error

observable_operator_test.go:443–451  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

441}
442
443func Test_Observable_Distinct_Error(t *testing.T) {
444 defer goleak.VerifyNone(t)
445 ctx, cancel := context.WithCancel(context.Background())
446 defer cancel()
447 obs := testObservable(ctx, 1, 2, 2, errFoo, 3).Distinct(func(_ context.Context, item interface{}) (interface{}, error) {
448 return item, nil
449 })
450 Assert(ctx, t, obs, HasItems(1, 2), HasError(errFoo))
451}
452
453func Test_Observable_Distinct_Error2(t *testing.T) {
454 defer goleak.VerifyNone(t)

Callers

nothing calls this directly

Calls 5

testObservableFunction · 0.85
AssertFunction · 0.85
HasItemsFunction · 0.85
HasErrorFunction · 0.85
DistinctMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…