@@ -82,23 +82,23 @@ val testHappyPathScript = """
82
82
83
83
84
84
85
- const feedbackButton = await page.waitForFunction(
86
- (expectedText) => {
87
- const buttons = document.querySelectorAll('button');
88
- return Array.from(buttons).find(button =>
89
- button.textContent.includes(expectedText)
90
- );
91
- },
92
- {timeout: 4000000},
93
- "How can we make /test better"
94
- );
95
-
96
- if (feedbackButton){
97
- console.log("Feedback button found with correct text")
98
- }else{
99
- console.log("Feedback button not found")
100
- throw new Error('Feedback button not found');
101
- }
85
+ // const feedbackButton = await page.waitForFunction(
86
+ // (expectedText) => {
87
+ // const buttons = document.querySelectorAll('button');
88
+ // return Array.from(buttons).find(button =>
89
+ // button.textContent.includes(expectedText)
90
+ // );
91
+ // },
92
+ // {timeout: 4000000},
93
+ // "How can we make /test better"
94
+ // );
95
+ //
96
+ // if (feedbackButton){
97
+ // console.log("Feedback button found with correct text")
98
+ // }else{
99
+ // console.log("Feedback button not found")
100
+ // throw new Error('Feedback button not found');
101
+ // }
102
102
} catch (e) {
103
103
console.log("Element with text not found")
104
104
console.log(e)
@@ -352,23 +352,23 @@ val testRejectPathScript = """
352
352
353
353
console.log("Input field re-enabled after rejection")
354
354
355
- const feedbackButton = await page.waitForFunction(
356
- (expectedText) => {
357
- const buttons = document.querySelectorAll('button');
358
- return Array.from(buttons).find(button =>
359
- button.textContent.includes(expectedText)
360
- );
361
- },
362
- {timeout: 4000000},
363
- "How can we make /test better"
364
- );
365
-
366
- if (feedbackButton){
367
- console.log("Feedback button found with correct text")
368
- }else{
369
- console.log("Feedback button not found")
370
- throw new Error('Feedback button not found');
371
- }
355
+ // const feedbackButton = await page.waitForFunction(
356
+ // (expectedText) => {
357
+ // const buttons = document.querySelectorAll('button');
358
+ // return Array.from(buttons).find(button =>
359
+ // button.textContent.includes(expectedText)
360
+ // );
361
+ // },
362
+ // {timeout: 4000000},
363
+ // "How can we make /test better"
364
+ // );
365
+ //
366
+ // if (feedbackButton){
367
+ // console.log("Feedback button found with correct text")
368
+ // }else{
369
+ // console.log("Feedback button not found")
370
+ // throw new Error('Feedback button not found');
371
+ // }
372
372
373
373
} catch (e) {
374
374
console.log("Element with text not found")
@@ -602,23 +602,23 @@ val testCancelButtonScript = """
602
602
603
603
console.log("Input field re-enabled after cancellation")
604
604
605
- const feedbackButton = await page.waitForFunction(
606
- (expectedText) => {
607
- const buttons = document.querySelectorAll('button');
608
- return Array.from(buttons).find(button =>
609
- button.textContent.includes(expectedText)
610
- );
611
- },
612
- {timeout: 4000000},
613
- "How can we make /test better"
614
- );
615
-
616
- if (feedbackButton){
617
- console.log("Feedback button found with correct text")
618
- }else{
619
- console.log("Feedback button not found")
620
- throw new Error('Feedback button not found');
621
- }
605
+ // const feedbackButton = await page.waitForFunction(
606
+ // (expectedText) => {
607
+ // const buttons = document.querySelectorAll('button');
608
+ // return Array.from(buttons).find(button =>
609
+ // button.textContent.includes(expectedText)
610
+ // );
611
+ // },
612
+ // {timeout: 4000000},
613
+ // "How can we make /test better"
614
+ // );
615
+ //
616
+ // if (feedbackButton){
617
+ // console.log("Feedback button found with correct text")
618
+ // }else{
619
+ // console.log("Feedback button not found")
620
+ // throw new Error('Feedback button not found');
621
+ // }
622
622
623
623
624
624
@@ -694,23 +694,23 @@ val testDocumentationErrorScript = """
694
694
695
695
console.log("Input field re-enabled after error")
696
696
697
- const feedbackButton = await page.waitForFunction(
698
- (expectedText) => {
699
- const buttons = document.querySelectorAll('button');
700
- return Array.from(buttons).find(button =>
701
- button.textContent.includes(expectedText)
702
- );
703
- },
704
- { timeout: 4000000 },
705
- "How can we make /test better"
706
- );
707
-
708
- if (feedbackButton){
709
- console.log("Feedback button found with correct text after error")
710
- }else{
711
- console.log("Feedback button not found")
712
- throw new Error('Feedback button not found');
713
- }
697
+ // const feedbackButton = await page.waitForFunction(
698
+ // (expectedText) => {
699
+ // const buttons = document.querySelectorAll('button');
700
+ // return Array.from(buttons).find(button =>
701
+ // button.textContent.includes(expectedText)
702
+ // );
703
+ // },
704
+ // { timeout: 4000000 },
705
+ // "How can we make /test better"
706
+ // );
707
+ //
708
+ // if (feedbackButton){
709
+ // console.log("Feedback button found with correct text after error")
710
+ // }else{
711
+ // console.log("Feedback button not found")
712
+ // throw new Error('Feedback button not found');
713
+ // }
714
714
715
715
} catch (e) {
716
716
console.log("Test failed")
@@ -784,23 +784,23 @@ val testRemoveFunctionErrorScript = """
784
784
785
785
console.log("Input field re-enabled after error")
786
786
787
- const feedbackButton = await page.waitForFunction(
788
- (expectedText) => {
789
- const buttons = document.querySelectorAll('button');
790
- return Array.from(buttons).find(button =>
791
- button.textContent.includes(expectedText)
792
- );
793
- },
794
- {timeout: 4000000},
795
- "How can we make /test better"
796
- );
797
-
798
- if (feedbackButton){
799
- console.log("Feedback button found with correct text after error")
800
- }else{
801
- console.log("Feedback button not found")
802
- throw new Error('Feedback button not found');
803
- }
787
+ // const feedbackButton = await page.waitForFunction(
788
+ // (expectedText) => {
789
+ // const buttons = document.querySelectorAll('button');
790
+ // return Array.from(buttons).find(button =>
791
+ // button.textContent.includes(expectedText)
792
+ // );
793
+ // },
794
+ // {timeout: 4000000},
795
+ // "How can we make /test better"
796
+ // );
797
+ //
798
+ // if (feedbackButton){
799
+ // console.log("Feedback button found with correct text after error")
800
+ // }else{
801
+ // console.log("Feedback button not found")
802
+ // throw new Error('Feedback button not found');
803
+ // }
804
804
805
805
} catch (e) {
806
806
console.log("Test failed")
@@ -874,23 +874,23 @@ val testMethodNotFoundErrorScript = """
874
874
875
875
console.log("Input field re-enabled after error")
876
876
877
- const feedbackButton = await page.waitForFunction(
878
- (expectedText) => {
879
- const buttons = document.querySelectorAll('button');
880
- return Array.from(buttons).find(button =>
881
- button.textContent.includes(expectedText)
882
- );
883
- },
884
- {timeout: 4000000},
885
- "How can we make /test better"
886
- );
887
-
888
- if (feedbackButton){
889
- console.log("Feedback button found with correct text after error")
890
- }else{
891
- console.log("Feedback button not found")
892
- throw new Error('Feedback button not found');
893
- }
877
+ // const feedbackButton = await page.waitForFunction(
878
+ // (expectedText) => {
879
+ // const buttons = document.querySelectorAll('button');
880
+ // return Array.from(buttons).find(button =>
881
+ // button.textContent.includes(expectedText)
882
+ // );
883
+ // },
884
+ // {timeout: 4000000},
885
+ // "How can we make /test better"
886
+ // );
887
+ //
888
+ // if (feedbackButton){
889
+ // console.log("Feedback button found with correct text after error")
890
+ // }else{
891
+ // console.log("Feedback button not found")
892
+ // throw new Error('Feedback button not found');
893
+ // }
894
894
895
895
} catch (e) {
896
896
console.log("Test failed")
0 commit comments