@@ -2811,7 +2811,6 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2811
2811
throw new Error('Expected to navigate to page1.html but got ' + currentURL);
2812
2812
}
2813
2813
2814
- // Go back to test page
2815
2814
await page.goto(testURL);
2816
2815
2817
2816
// Test glob pattern - matches page2.html
@@ -2824,7 +2823,6 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2824
2823
throw new Error('Expected to navigate to page2.html but got ' + currentURL);
2825
2824
}
2826
2825
2827
- // Go back to test page
2828
2826
await page.goto(testURL);
2829
2827
2830
2828
// Test glob pattern with query string
@@ -2837,7 +2835,6 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2837
2835
throw new Error('Expected to navigate to page1.html?test=true but got ' + currentURL);
2838
2836
}
2839
2837
2840
- // Go back to test page
2841
2838
await page.goto(testURL);
2842
2839
2843
2840
// Test regex pattern - matches any page with .html extension
@@ -2850,7 +2847,6 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2850
2847
throw new Error('Expected URL to end with .html but got ' + currentURL);
2851
2848
}
2852
2849
2853
- // Go back to test page
2854
2850
await page.goto(testURL);
2855
2851
2856
2852
// Test regex pattern with query parameters
@@ -2863,7 +2859,6 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2863
2859
throw new Error('Expected to navigate to page2.html?test=true but got ' + currentURL);
2864
2860
}
2865
2861
2866
- // Go back to test page
2867
2862
await page.goto(testURL);
2868
2863
2869
2864
// Test timeout when URL doesn't match
@@ -2884,8 +2879,9 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2884
2879
throw new Error('Expected timeout error when URL does not match');
2885
2880
}
2886
2881
2887
- // Test character class in glob pattern
2888
2882
await page.goto(testURL);
2883
+
2884
+ // Test character class in glob pattern
2889
2885
await Promise.all([
2890
2886
page.waitForNavigation({ url: '**/page[12].html' }),
2891
2887
page.click('#page1')
@@ -2895,8 +2891,9 @@ func TestWaitForNavigationWithURL(t *testing.T) {
2895
2891
throw new Error('Expected to navigate to page1.html with character class pattern but got ' + currentURL);
2896
2892
}
2897
2893
2898
- // Test empty pattern (matches any navigation)
2899
2894
await page.goto(testURL);
2895
+
2896
+ // Test empty pattern (matches any navigation)
2900
2897
await Promise.all([
2901
2898
page.waitForNavigation({ url: '' }),
2902
2899
page.click('#page2')
0 commit comments