forked from TingtingWen/wopi-validator-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
FeatureTestCases.xml
221 lines (209 loc) · 8.97 KB
/
FeatureTestCases.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
<?xml version="1.0" encoding="utf-8"?>
<WopiValidation>
<Resources>
<!-- Contains files that can be used by test cases -->
<File Id="WordBlankDocument" Name="WordBlankDocument.docx" FilePath="Resources\WordBlankDocument.docx" />
<File Id="WordSimpleDocument" Name="WordSimpleDocument.docx" FilePath="Resources\WordSimpleDocument.docx" />
<File Id="WordZeroByteDocument" Name="WordZeroBytesDocument.docx" FilePath="Resources\WordZeroBytesDocument.docx" />
<File Id="ExcelBlankWorkbook" Name="ExcelBlankWorkbook.xlsx" FilePath="Resources\ExcelBlankWorkbook.xlsx" />
</Resources>
<PrereqCases>
<TestCase Name="BusinessFlowPrereqs" Document="WordBlankDocument" Category="WopiCore">
<Description>
The prereq BusinessFlowPrereqs must pass prior to running the feature validations related to business flows.
</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="LicenseCheckForEditIsEnabled" IsRequired="true" ExpectedValue="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
</PrereqCases>
<TestGroup Name="Features">
<TestCases>
<TestCase
Name="Feature.FileSharing"
Document="WordBlankDocument"
UiScreenshot="Feature.FileSharing.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/wopi/files/CheckFileInfo.html?highlight=sharing#term-filesharingurl"
FailMessage="File sharing not available."
Category="WopiCore">
<Description>Checks the support for the file sharing feature</Description>
<Requests>
<CheckFile>
<Validators>
<Or>
<JsonResponseContentValidator>
<AbsoluteUrlProperty Name="FileSharingUrl" IsRequired="true" />
</JsonResponseContentValidator>
<JsonResponseContentValidator>
<BooleanProperty Name="FileSharingPostMessage" ExpectedValue="true" />
</JsonResponseContentValidator>
</Or>
</Validators>
</CheckFile>
</Requests>
</TestCase>
<TestCase
Name="Feature.Download"
Document="WordBlankDocument"
UiScreenshot="Feature.Download.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/wopi/files/CheckFileInfo.html?highlight=downloadurl#term-downloadurl"
FailMessage="Download is not available."
Category="WopiCore">
<Description>Checks the support for the download functionality (Download a Copy, Download as PDF and Download as ODT features).</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<AbsoluteUrlProperty Name="DownloadUrl" IsRequired="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
<TestCase
Name="Feature.Rename"
Document="WordBlankDocument"
UiScreenshot="Feature.Rename.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/wopi/files/RenameFile.html#renamefile"
FailMessage="Rename not available."
Category="WopiCore">
<Description>Checks the support for the 'Rename' functionality.</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="SupportsRename" IsRequired="true" />
<BooleanProperty Name="UserCanRename" IsRequired="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
<TestCase
Name="Feature.PostMessage"
Document="WordBlankDocument"
DocumentationLink="https://wopi.readthedocs.org/en/latest/scenarios/postmessage.html#postmessage"
FailMessage="PostMessage not available."
Category="WopiCore">
<Description>
Checks whether the host can integrate with Office Online by using the HTML5 Web Messaging Protocol.
Enabling PostMessage allows hosts to use their own UI for specific actions on Office Online.
</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<AbsoluteUrlProperty Name="PostMessageOrigin" IsRequired="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
<TestCase
Name="Feature.ExcelSaveAs"
Document="ExcelBlankWorkbook"
UiScreenshot="Feature.ExcelSaveAs.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/wopi/files/PutRelativeFile.html?highlight=excel"
FailMessage="Save As in Excel not available."
Category="WopiCore">
<Description>
Checks whether host supports the Save As feature in Excel.
</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="UserCannotWriteRelative" ExpectedValue="false" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
<PutRelativeFile Type="Relative" Name="SuggestedName.xlsx" ResourceId="ExcelBlankWorkbook">
<SaveState>
<State Name="NewFileUrl1" Source="Url" />
</SaveState>
<Validators>
<JsonResponseContentValidator>
<StringProperty Name="Name" ExpectedValue="SuggestedName.xlsx" IsRequired="true"/>
<StringProperty Name="Url" IsRequired="true"/>
<StringProperty Name="HostViewUrl" IsRequired="true"/>
<StringProperty Name="HostEditUrl" IsRequired="true"/>
</JsonResponseContentValidator>
</Validators>
</PutRelativeFile>
</Requests>
<CleanupRequests>
<DeleteFile OverrideUrl="$State:NewFileUrl1"/>
</CleanupRequests>
</TestCase>
<TestCase
Name="Feature.AllowExternalSpellCheckService"
Document="WordBlankDocument"
UiScreenshot="Feature.AllowOneSpellerProofing.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/wopi/files/AllowExternalSpellCheckService.html"
FailMessage="AllowExternalSpellCheckService is not available."
Category="WopiCore">
<Description>Checks the support to AllowExternalSpellCheckService functionality. Currently this service is the Bing proofing service.</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="AllowExternalSpellCheckService" ExpectedValue="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
</TestCases>
</TestGroup>
<!-- Business Flow test cases -->
<TestGroup Name="Features.BusinessFlow">
<PrereqTests>
<PrereqTest>BusinessFlowPrereqs</PrereqTest>
</PrereqTests>
<TestCases>
<TestCase
Name="Feature.BusinessFlow"
Document="WordBlankDocument"
UiScreenshot="Feature.BusinessFlow.png"
DocumentationLink="https://wopi.readthedocs.org/en/latest/scenarios/business.html?highlight=business"
FailMessage="Document editing for business users not available."
Category="WopiCore">
<Description>Checks the support for Document editing for business users.</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="LicenseCheckForEditIsEnabled" ExpectedValue="true" IsRequired="true" />
<AbsoluteUrlProperty Name="HostEditUrl" IsRequired="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
<TestCase
Name="Feature.SupportsUserInfo"
Document="WordBlankDocument"
DocumentationLink="https://wopi.readthedocs.org/en/latest/scenarios/business.html?highlight=business#tracking-users-subscription-status"
FailMessage="PutUserInfo not available"
Category="WopiCore">
<Description>Checks the support PutUserInfo WOPI operations in business documents.</Description>
<Requests>
<CheckFile>
<Validators>
<JsonResponseContentValidator>
<BooleanProperty Name="LicenseCheckForEditIsEnabled" ExpectedValue="true" IsRequired="true" />
<BooleanProperty Name="SupportsUserInfo" ExpectedValue="true" IsRequired="true" />
</JsonResponseContentValidator>
</Validators>
</CheckFile>
</Requests>
</TestCase>
</TestCases>
</TestGroup>
</WopiValidation>