Skip to content

Commit 925fe9b

Browse files
committed
Update nestedAppAuth.json to include E2E tests
1 parent 57901e9 commit 925fe9b

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

apps/teams-test-app/e2e-test-data/nestedAppAuth.json

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,71 @@
22
"name": "nestedAppAuth",
33
"platforms": "*",
44
"version": ">=2.22.0",
5+
"cypressTopWindowReplacement": true,
56
"testCases": [
67
{
78
"title": "nestedAppAuth isNAAChannelRecommended API Call - Success",
89
"type": "callResponse",
910
"boxSelector": "#box_checkIsNAAChannelRecommended",
1011
"expectedTestAppValue": "NAA channel is recommended"
12+
},
13+
{
14+
"title": "nestedAppAuth - Send NAA message to NAA bridge from parent window",
15+
"type": "callResponse",
16+
"boxSelector": "#box_sendMessageToNestedAppAuthBridge",
17+
"inputValue": {
18+
"messageType": "NestedAppAuthRequest",
19+
"method": "GetToken",
20+
"sendTime": 1732269811006,
21+
"clientLibrary": "MetaOS",
22+
"clientLibraryVersion": "1.0.0",
23+
"requestId": "684352c2-7ab7-4def-b7e1-56a386c02a0a",
24+
"tokenParams": { "correlationId": "39dc85fe-9054-11ed-a1eb-0242ac120002" }
25+
},
26+
"expectedAlertValue": "nestedAppAuth.execute called with payload: ##JSON_INPUT_VALUE##, origin: https://localhost:4000/, isTrustedOrigin: true",
27+
"expectedTestAppValue": {
28+
"messageType": "NestedAppAuthResponse",
29+
"requestId": "684352c2-7ab7-4def-b7e1-56a386c02a0a",
30+
"success": true,
31+
"initContext": {
32+
"sdkName": "OfficeAuth",
33+
"sdkVersion": "16.0.18015.15000",
34+
"capabilities": { "queryAccount": false },
35+
"accountContext": {
36+
"homeAccountId": "bb5r835b-0e7b",
37+
"environment": "login.windows.net",
38+
"tenantId": "2855cd1be"
39+
}
40+
}
41+
}
42+
},
43+
{
44+
"title": "nestedAppAuth - Send NAA message to top window from parent window",
45+
"type": "callResponse",
46+
"boxSelector": "#box_sendMessageToTopWindow",
47+
"platformsExcluded": ["iOS"],
48+
"inputValue": {
49+
"id": "2",
50+
"func": "nestedAppAuth.execute",
51+
"args": [],
52+
"data": "{\"messageType\":\"NestedAppAuthRequest\",\"method\":\"GetToken\",\"sendTime\":1732269811006,\"clientLibrary\":\"MetaOS\",\"clientLibraryVersion\":\"1.0.0\",\"requestId\":\"684352c2-7ab7-4def-b7e1-56a386c02a0a\",\"tokenParams\":{\"correlationId\":\"39dc85fe-9054-11ed-a1eb-0242ac120002\"}}"
53+
},
54+
"expectedAlertValue": "nestedAppAuth.execute called with payload: {\"messageType\":\"NestedAppAuthRequest\",\"method\":\"GetToken\",\"sendTime\":1732269811006,\"clientLibrary\":\"MetaOS\",\"clientLibraryVersion\":\"1.0.0\",\"requestId\":\"684352c2-7ab7-4def-b7e1-56a386c02a0a\",\"tokenParams\":{\"correlationId\":\"39dc85fe-9054-11ed-a1eb-0242ac120002\"}}, origin: https://localhost:4000/, isTrustedOrigin: true",
55+
"expectedTestAppValue": {
56+
"messageType": "NestdedAppAuthResponse",
57+
"requestId": "684352c2-7ab7-4def-b7e1-56a386c02a0a",
58+
"success": true,
59+
"initContext": {
60+
"sdkName": "OfficeAuth",
61+
"sdkVersion": "16.0.18015.15000",
62+
"capabilities": { "queryAccount": false },
63+
"accountContext": {
64+
"homeAccountId": "bb5r835b-0e7b",
65+
"environment": "login.windows.net",
66+
"tenantId": "2855cd1be"
67+
}
68+
}
69+
}
1170
}
1271
]
1372
}

0 commit comments

Comments
 (0)