You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
assert.Equal(t, `[<a href="http://localhost:3000/test/repo">test/repo</a>] Repository created by <a href="https://try.gitea.io/user1">user1</a>`, pl.(*MatrixPayload).FormattedBody)
156
156
})
157
157
158
+
t.Run("Package", func(t*testing.T) {
159
+
p:=packageTestPayload()
160
+
161
+
d:=new(MatrixPayload)
162
+
pl, err:=d.Package(p)
163
+
require.NoError(t, err)
164
+
require.NotNil(t, pl)
165
+
require.IsType(t, &MatrixPayload{}, pl)
166
+
167
+
assert.Equal(t, `[[GiteaContainer](http://localhost:3000/user1/-/packages/container/GiteaContainer/latest)] Package published by [user1](https://try.gitea.io/user1)`, pl.(*MatrixPayload).Body)
168
+
assert.Equal(t, `[<a href="http://localhost:3000/user1/-/packages/container/GiteaContainer/latest">GiteaContainer</a>] Package published by <a href="https://try.gitea.io/user1">user1</a>`, pl.(*MatrixPayload).FormattedBody)
0 commit comments