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
@@ -22,9 +22,16 @@ describe('CodeceptJS step-sections', function () {
22
22
expect(stdout).toContain('User Journey')
23
23
expect(stdout).toContain('Nothing to say')
24
24
25
-
constexpectedOutput=[' I am in path "."',' User Journey',' I act "Hello, World!"',' I act "Nothing to say"'].join('\n')
25
+
// Check for the step structure (allowing for timing info in between)
26
+
expect(stdout).toContain('I am in path "."')
27
+
expect(stdout).toContain('User Journey')
28
+
expect(stdout).toContain('I act "Hello, World!"')
29
+
expect(stdout).toContain('I act "Nothing to say"')
30
+
31
+
// Verify the indentation structure for sections
32
+
expect(stdout).toMatch(/\s+UserJourney/)
33
+
expect(stdout).toMatch(/\s+Iact"Hello,World!"/)
26
34
27
-
expect(stdout).toContain(expectedOutput)
28
35
expect(err).toBeFalsy()
29
36
done()
30
37
})
@@ -36,9 +43,19 @@ describe('CodeceptJS step-sections', function () {
36
43
expect(stdout).toContain('OK')
37
44
expect(stdout).toContain('User Journey')
38
45
39
-
constexpectedOutput=[' User Journey',' On userPage: act on page',' I act "actOnPage"',' I act "see on this page"',' I act "One more step"',' I act "Nothing to say"'].join('\n')
46
+
// Check for the step structure (allowing for timing info in between)
47
+
expect(stdout).toContain('User Journey')
48
+
expect(stdout).toContain('On userPage: act on page')
49
+
expect(stdout).toContain('I act "actOnPage"')
50
+
expect(stdout).toContain('I act "see on this page"')
51
+
expect(stdout).toContain('I act "One more step"')
52
+
expect(stdout).toContain('I act "Nothing to say"')
53
+
54
+
// Verify the indentation structure for sections and nested steps
0 commit comments