Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Commit

Permalink
fix encode plugin data unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
marcoandredinis committed Oct 19, 2023
1 parent 9feaed9 commit 28723a9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion access/msteams/plugindata_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,14 @@ const messageData = "eyJpZCI6IkNIQU5ORUwxIiwidHMiOiIwMDAwMDAxIiwicmlkIjoiZm9vQGV
func TestEncodePluginData(t *testing.T) {
dataMap, err := EncodePluginData(samplePluginData)
assert.NoError(t, err)
assert.Len(t, dataMap, 7)
assert.GreaterOrEqual(t, dataMap, 8)
assert.Equal(t, "user-foo", dataMap["user"])
assert.Equal(t, "role-foo,role-bar", dataMap["roles"])
assert.Equal(t, "foo reason", dataMap["request_reason"])
assert.Equal(t, "3", dataMap["reviews_count"])
assert.Equal(t, "APPROVED", dataMap["resolution"])
assert.Equal(t, "foo ok", dataMap["resolve_reason"])
assert.Equal(t, "", dataMap["resources"])
assert.Equal(
t,
messageData,
Expand Down

0 comments on commit 28723a9

Please sign in to comment.