From 97146f7e790128877e8737b2c24d50cc0c20ffbd Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 30 Apr 2021 10:48:19 -0400 Subject: [PATCH] Switch to the stable space endpoint. --- tests/msc2946_test.go | 8 ++++---- tests/msc3083_test.go | 6 +----- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/tests/msc2946_test.go b/tests/msc2946_test.go index 75313f81..95b6d1c9 100644 --- a/tests/msc2946_test.go +++ b/tests/msc2946_test.go @@ -13,8 +13,8 @@ import ( ) var ( - spaceChildEventType = "org.matrix.msc1772.space.child" - spaceParentEventType = "org.matrix.msc1772.space.parent" + spaceChildEventType = "m.space.child" + spaceParentEventType = "m.space.parent" ) // the API doesn't return event IDs so we need to key off the @@ -71,7 +71,7 @@ func TestClientSpacesSummary(t *testing.T) { "name": "Sub-Space 1", "topic": "Some topic for sub-space 1", "creation_content": map[string]interface{}{ - "org.matrix.msc1772.type": "org.matrix.msc1772.space", + "type": "m.space", }, }) roomNames[ss1] = "Sub-Space 1" @@ -184,7 +184,7 @@ func TestClientSpacesSummary(t *testing.T) { } } if roomID == ss1 { - wantType := "org.matrix.msc1772.space" + wantType := "m.space" if data.Get("room_type").Str != wantType { return fmt.Errorf("room %s got type %s want %s", roomID, data.Get("room_type").Str, wantType) } diff --git a/tests/msc3083_test.go b/tests/msc3083_test.go index 3ddb0449..9248a75b 100644 --- a/tests/msc3083_test.go +++ b/tests/msc3083_test.go @@ -14,10 +14,6 @@ import ( "github.com/matrix-org/complement/internal/docker" ) -var ( - msc1772SpaceChildEventType = "org.matrix.msc1772.space.child" -) - func FailJoinRoom(c *client.CSAPI, t *testing.T, roomIDOrAlias string, serverName string) { // This is copied from Client.JoinRoom to test a join failure. query := make(url.Values, 1) @@ -64,7 +60,7 @@ func SetupRestrictedRoom(t *testing.T, deployment *docker.Deployment) (*client.C }, }) alice.SendEventSynced(t, space, b.Event{ - Type: msc1772SpaceChildEventType, + Type: "m.space.child", StateKey: &room, Content: map[string]interface{}{ "via": []string{"hs1"},