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
Copy file name to clipboardExpand all lines: docs/test/extending-coded-ui-tests-and-action-recordings-to-support-microsoft-excel.md
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ ms.workload:
10
10
- "multiple"
11
11
author: gewarren
12
12
---
13
-
# Extend Coded UI Tests and Action Recordings
13
+
# Extend coded UI tests and action recordings
14
14
15
15
The testing framework for coded UI tests and action recordings does not support every possible user interface. It might not support the specific UI that you want to test. For example, you cannot immediately create a coded UI test or an action recording for a Microsoft Excel spreadsheet. However, you can create your own extension to the coded UI test framework that supports your specific UI by taking advantage of the extensibility of the coded UI test framework.
16
16
@@ -29,6 +29,6 @@ This [blog post](https://blogs.msdn.microsoft.com/gautamg/2010/01/05/3-introduci
-[Use UI Automation To Test Your Code](../test/use-ui-automation-to-test-your-code.md)
33
-
-[Best Practices for Coded UI Tests](../test/best-practices-for-coded-ui-tests.md)
34
-
-[Supported Configurations and Platforms for Coded UI Tests and Action Recordings](../test/supported-configurations-and-platforms-for-coded-ui-tests-and-action-recordings.md)
32
+
-[Use UI automation to test your code](../test/use-ui-automation-to-test-your-code.md)
33
+
-[Best practices for coded UI tests](../test/best-practices-for-coded-ui-tests.md)
34
+
-[Supported configurations and platforms for coded UI tests and action recordings](../test/supported-configurations-and-platforms-for-coded-ui-tests-and-action-recordings.md)
Copy file name to clipboardExpand all lines: docs/test/fix-non-detectable-dynamic-parameters-in-a-web-performance-test.md
+33-33Lines changed: 33 additions & 33 deletions
Original file line number
Diff line number
Diff line change
@@ -29,11 +29,11 @@ Some types of dynamic parameters are not detected. An undetected dynamic paramet
29
29
30
30
To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll create a simple ASP.NET web application that has three web forms with a few controls and some custom code. We’ll then learn how to isolate the dynamic parameters and how to handle them.
31
31
32
-
1. Create a new ASP.NET project named DynamicParamaterSample.
32
+
1. Create a new ASP.NET project named **DynamicParameterSample**.
33
33
34
34

35
35
36
-
2. Add a web form named Querystring.aspx.
36
+
2. Add a web form named *Querystring.aspx*.
37
37
38
38
3. In design view, drag a HiddenField onto the page and in then in change the value for the (ID) property to HiddenFieldSessionID.
39
39
@@ -56,7 +56,7 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
56
56
</html>
57
57
```
58
58
59
-
5. Open the Querystring.aspx.cs file and add the following highlighted code to the Page_Load method:
59
+
5. Open the *Querystring.aspx.cs* file and add the following highlighted code to the Page_Load method:
60
60
61
61
```csharp
62
62
public partial class Querystring : System.Web.UI.Page
@@ -68,25 +68,25 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
68
68
}
69
69
```
70
70
71
-
6. Add a second web form named ASPQuery.aspx.
71
+
6. Add a second web form named *ASPQuery.aspx*.
72
72
73
-
7. In design view, drag a Label onto the page and change the value for its (ID) property to IndexLabel.
73
+
7. In design view, drag a **Label** onto the page and change the value for its **(ID)** property to **IndexLabel**.
74
74
75
75

76
76
77
-
8. Drag a HyperLink onto the page and change the vale for its Text property to Back.
77
+
8. Drag a **HyperLink** onto the page and change the vale for its **Text** property to **Back**.
78
78
79
79

80
80
81
-
9. Choose (…) for the NavigationURL property.
81
+
9. Choose **(…)** for the **NavigationURL** property.
82
82
83
83

84
84
85
-
Select Querystring.aspx.
85
+
Select *Querystring.aspx*.
86
86
87
87

88
88
89
-
10. Open the ASPQuery.aspx.cs file, and add the following highlighted code to the Page_Load method:
89
+
10. Open the *ASPQuery.aspx.cs* file, and add the following highlighted code to the Page_Load method:
@@ -95,13 +95,13 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
95
95
}
96
96
```
97
97
98
-
11. Add a third web form named JScriptQuery.aspx.
98
+
11. Add a third web form named *JScriptQuery.aspx*.
99
99
100
-
Just as we did for the second page, drag a label onto the form, setting its (ID) property to IndexLabel and drag a Hyperlink onto the form, setting its text property to Back, and its NavigationURL property to Querystring.aspx.
100
+
Just as we did for the second page, drag a **Label** onto the form, setting its **(ID)** property to **IndexLabel** and drag a **Hyperlink** onto the form, setting its **Text** property to **Back**, and its **NavigationURL** property to **Querystring.aspx**.
101
101
102
102

103
103
104
-
12. Open the JScriptQuery.aspx.cs file, and add the following highlighted code to the Page_Load method:
104
+
12. Open the *JScriptQuery.aspx.cs* file, and add the following highlighted code to the Page_Load method:
@@ -112,11 +112,11 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
112
112
113
113
13. Save the project.
114
114
115
-
14. In Solution Explorer, set the Querystring.aspx as the start page.
115
+
14. In **Solution Explorer**, set the *Querystring.aspx* as the start page.
116
116
117
117

118
118
119
-
15. Press CTRL+F5 to run the web application in the browser. Copy the URL. You will need it when you record your test.
119
+
15. Press **Ctrl**+**F5** to run the web application in the browser. Copy the URL. You will need it when you record your test.
120
120
121
121
16. Try both links. They should each display the message "Success. Dynamic querystring parameter found."
122
122
@@ -146,21 +146,21 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
146
146
147
147
The web test recorder displays the HTTP request and response URLs as you navigate through the web app.
148
148
149
-
6. Choose the stop button on the test recorder.
149
+
6. Choose the **Stop** button on the test recorder.
150
150
151
151
The dialog box for detecting dynamic parameters displays a progress bar that shows the status of parameter detection in the HTTP responses that were received.
152
152
153
153
7. The dynamic parameter for CustomQueryString in the ASPQuery page is automatically detected. However, The dynamic parameter for CustomQueryString in the JScriptQuery page is not detected.
154
154
155
-
Choose OK to add an extraction rule to Querystring.aspx, binding it to the ASPQuery page.
155
+
Choose **OK** to add an extraction rule to *Querystring.aspx*, binding it to the ASPQuery page.
156
156
157
157

158
158
159
-
The extraction rule is added to the first request for Querystring.aspx.
159
+
The extraction rule is added to the first request for *Querystring.aspx*.
160
160
161
161

162
162
163
-
Expand the second request in the request tree for ASPQuery.aspx and notice that the CustomQueryString's value has been bound to the extraction rule.
163
+
Expand the second request in the request tree for *ASPQuery.aspx* and notice that the CustomQueryString's value has been bound to the extraction rule.
164
164
165
165

166
166
@@ -172,21 +172,21 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
172
172
173
173

174
174
175
-
2. The fourth request for the JScriptQuery.aspx page fails. Go to the web test.
175
+
2. The fourth request for the *JScriptQuery.aspx* page fails. Go to the web test.
176
176
177
177

178
178
179
-
The JScriptQuery.aspx request node is highlighted in the editor. Expand the node and notice that the "1v0yhyiyr0raa2w4j4pwf5zl" portion of the CustomQueryString appears to be dynamic.
179
+
The *JScriptQuery.aspx* request node is highlighted in the editor. Expand the node and notice that the "1v0yhyiyr0raa2w4j4pwf5zl" portion of the CustomQueryString appears to be dynamic.
180
180
181
181

182
182
183
-
3. Return to the Web Performance Test Results Viewer and select the JScriptQuery.aspx page that failed. Then, choose the request tab, verify that the show raw data check box is cleared, scroll down and choose quick find on the CustomQueryString.
183
+
3. Return to the Web Performance Test Results Viewer and select the *JScriptQuery.aspx* page that failed. Then, choose the request tab, verify that the show raw data check box is cleared, scroll down and choose quick find on the CustomQueryString.
184
184
185
185

186
186
187
-
4. We know from looking at the test editor, that the JScriptQuery.aspx request's CustomQueryString was assigned a value of: `jScriptQueryString___1v0yhyiyr0raa2w4j4pwf5zl`, and that the suspected dynamic portion is "1v0yhyiyr0raa2w4j4pwf5zl". In the find what drop-down list, remove the suspect portion of the search string. The string should be "CustomQueryString=jScriptQueryString___".
187
+
4. We know from looking at the test editor, that the *JScriptQuery.aspx* request's CustomQueryString was assigned a value of: `jScriptQueryString___1v0yhyiyr0raa2w4j4pwf5zl`, and that the suspected dynamic portion is "1v0yhyiyr0raa2w4j4pwf5zl". In the find what drop-down list, remove the suspect portion of the search string. The string should be "CustomQueryString=jScriptQueryString___".
188
188
189
-
Dynamic parameters are assigned their values in one of the requests that precedes the request that has the error. Therefore, select the search up check box and choose find next until you see preceding request for Querystring.aspx highlighted in the request panel. This should occur after you choose find next three times.
189
+
Dynamic parameters are assigned their values in one of the requests that precedes the request that has the error. Therefore, select the search up check box and choose find next until you see preceding request for *Querystring.aspx* highlighted in the request panel. This should occur after you choose find next three times.
190
190
191
191

192
192
@@ -209,33 +209,33 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
209
209
210
210

211
211
212
-
7. In the recorded results, select the third request, which is the same Querystringrequest.aspx request that you isolated in the test run results.
212
+
7. In the recorded results, select the third request, which is the same *Querystringrequest.aspx* request that you isolated in the test run results.
213
213
214
214

215
215
216
216
Choose the response tab, scroll down and choose the original dynamic parameter value of "1v0yhyiyr0raa2w4j4pwf5zl" that you isolated previously and add an extraction rule.
217
217
218
218

219
219
220
-
The new extraction rule is added to the Querystring.aspx request and is assigned a value of 'Param0'.
220
+
The new extraction rule is added to the *Querystring.aspx* request and is assigned a value of 'Param0'.
221
221
222
-
If the dialog box informs us that matches were found for the extracted text to bind the parameter to, choose yes.
222
+
If the dialog box informs us that matches were found for the extracted text to bind the parameter to, choose **Yes**.
8. Choose find next. The first match is the one that we need to change, which is the parameter for CustomQueryString in for the JScriptQuery page.
226
+
8. Choose **Find Next**. The first match is the one that we need to change, which is the parameter for CustomQueryString in for the JScriptQuery page.
227
227
228
228

229
229
230
-
9. Choose replace.
230
+
9. Choose **Replace**.
231
231
232
232

233
233
234
-
The QueryString parameter under the JScriptQuery.aspx request is updated by using the new context parameter: CustomQueryString=jScriptQueryString___{{Param0}}.
234
+
The QueryString parameter under the *JScriptQuery.aspx* request is updated by using the new context parameter: CustomQueryString=jScriptQueryString___{{Param0}}.
235
235
236
236

237
237
238
-
10. Close the find and replace dialog. Notice the similar structure of in the request tree between the detected dynamic parameter and the non-detected dynamic parameter that you correlated.
238
+
10. Close the **Find and Replace** dialog. Notice the similar structure of in the request tree between the detected dynamic parameter and the non-detected dynamic parameter that you correlated.
239
239
240
240

241
241
@@ -247,13 +247,13 @@ To demonstrate both a detectable and a non-detectable dynamic parameter, we’ll
247
247
248
248
**A:** Yes, use the following procedure:
249
249
250
-
1. In the toolbar, choose the Promote Dynamic Parameters to Web Test Parameters button.
250
+
1. In the toolbar, choose the **Promote Dynamic Parameters to Web Test Parameters** button.
251
251
252
-
After the detection process completes, if any dynamic parameters are detected, the Promote Dynamic Parameters to web test parameters dialog box appears.
252
+
After the detection process completes, if any dynamic parameters are detected, the **Promote Dynamic Parameters to web test parameters** dialog box appears.
253
253
254
254
The dynamic parameters are listed under the Dynamic Parameters column. The requests that the dynamic parameter will be extracted from and bound to are listed under the Extract Parameter from Response and Bind to Request columns.
255
255
256
-
If you choose a dynamic parameter in the Promote Dynamic Parameters to web test parameters dialog box, two requests will be highlighted in the Web Performance Test Editor request tree. The first request will be the request that the extraction rule will be added to. The second request is where the extracted value will be bound.
256
+
If you choose a dynamic parameter in the **Promote Dynamic Parameters to web test parameters** dialog box, two requests will be highlighted in the Web Performance Test Editor request tree. The first request will be the request that the extraction rule will be added to. The second request is where the extracted value will be bound.
257
257
258
258
2. Select or clear the check box next to the dynamic parameters you would like to automatically correlate. By default, all the dynamic parameters are checked.
When you run a coded test with a data source, you might see the following error message:
88
88
@@ -91,4 +91,4 @@ Web performance tests are recorded by browsing through your web app. The tests a
91
91
This can occur because you have a DataSourceAttribute defined for the test class, without a corresponding DataBindingAttribute. To resolve this error, add an appropriate DataBindingAttribute, delete it, or comment it out of the code.
92
92
93
93
### Q: Should I add validation and extraction rules before or after I generate a coded test?
94
-
**A:** It is easier to validation rules and extraction rules before you generate the coded test; however, werecommendthatyouuse [codedUItests](../test/use-ui-automation-to-test-your-code.md) for validation purposes.
94
+
**A:** It is easier to add validation rules and extraction rules before you generate the coded test; however, werecommendthatyouuse [codedUItests](../test/use-ui-automation-to-test-your-code.md) for validation purposes.
0 commit comments