(t *testing.T)
| 881 | } |
| 882 | |
| 883 | func TestTopicOwnerChange(t *testing.T) { |
| 884 | err := adp.TopicOwnerChange(testData.Topics[0].Id, types.ParseUserId("usr"+testData.Users[1].Id)) |
| 885 | if err != nil { |
| 886 | t.Fatal(err) |
| 887 | } |
| 888 | var got int64 |
| 889 | err = db.QueryRow(ctx, "SELECT owner FROM topics WHERE name=$1", testData.Topics[0].Id).Scan(&got) |
| 890 | if err != nil { |
| 891 | t.Fatal(err) |
| 892 | } |
| 893 | expectedOwner := decodeUid(testData.Users[1].Id) |
| 894 | if got != expectedOwner { |
| 895 | t.Error(mismatchErrorString("Owner", got, expectedOwner)) |
| 896 | } |
| 897 | } |
| 898 | |
| 899 | func TestSubsUpdate(t *testing.T) { |
| 900 | update := map[string]any{ |
nothing calls this directly
no test coverage detected
searching dependent graphs…