From 611f9de39b7a29e89616c9ffe76d2aca1194877b Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Tue, 11 Jun 2024 11:54:59 +0200 Subject: [bugfix] Deref stats async, serve stub collections if handshaking (#2990) * [bugfix] Deref stats async, allow peek if handshaking * don't return totalItems when handshaking or hiding collections * use GetLimit() * use StubAccountStats --- internal/typeutils/internaltoas_test.go | 21 --------------------- 1 file changed, 21 deletions(-) (limited to 'internal/typeutils/internaltoas_test.go') diff --git a/internal/typeutils/internaltoas_test.go b/internal/typeutils/internaltoas_test.go index 740938220..26e86c516 100644 --- a/internal/typeutils/internaltoas_test.go +++ b/internal/typeutils/internaltoas_test.go @@ -366,27 +366,6 @@ func (suite *InternalToASTestSuite) TestAccountToASWithSharedInbox() { }`, trimmed) } -func (suite *InternalToASTestSuite) TestOutboxToASCollection() { - testAccount := suite.testAccounts["admin_account"] - ctx := context.Background() - - collection, err := suite.typeconverter.OutboxToASCollection(ctx, testAccount.OutboxURI) - suite.NoError(err) - - ser, err := ap.Serialize(collection) - suite.NoError(err) - - bytes, err := json.MarshalIndent(ser, "", " ") - suite.NoError(err) - - suite.Equal(`{ - "@context": "https://www.w3.org/ns/activitystreams", - "first": "http://localhost:8080/users/admin/outbox?page=true", - "id": "http://localhost:8080/users/admin/outbox", - "type": "OrderedCollection" -}`, string(bytes)) -} - func (suite *InternalToASTestSuite) TestStatusToAS() { testStatus := suite.testStatuses["local_account_1_status_1"] ctx := context.Background() -- cgit v1.2.3