(t *testing.T)
| 523 | } |
| 524 | |
| 525 | func TestSubscriptionGet(t *testing.T) { |
| 526 | got, err := adp.SubscriptionGet(testData.Topics[0].Id, types.ParseUserId("usr"+testData.Users[0].Id), false) |
| 527 | if err != nil { |
| 528 | t.Error(err) |
| 529 | } |
| 530 | |
| 531 | if diff := cmp.Diff(got, testData.Subs[0], |
| 532 | cmpopts.IgnoreUnexported(types.Subscription{}, types.ObjHeader{})); diff != "" { |
| 533 | t.Error(mismatchErrorString("Subs", diff, "")) |
| 534 | } |
| 535 | // Test not found |
| 536 | got, err = adp.SubscriptionGet("dummytopic", dummyUid1, false) |
| 537 | if err != nil { |
| 538 | t.Error(err) |
| 539 | } |
| 540 | if got != nil { |
| 541 | t.Error("result sub should be nil.") |
| 542 | } |
| 543 | } |
| 544 | |
| 545 | func TestSubsForUser(t *testing.T) { |
| 546 | gotSubs, err := adp.SubsForUser(types.ParseUserId("usr" + testData.Users[0].Id)) |
nothing calls this directly
no test coverage detected
searching dependent graphs…