Skip to content

Commit 04ad53d

Browse files
triaging of spec test failures
1 parent c085b64 commit 04ad53d

File tree

3 files changed

+10
-17
lines changed

3 files changed

+10
-17
lines changed

assembly/__spec_tests__/generated.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ it("line: 71 - matches ((((((((((((((((((((((((((((((x))))))))))))))))))))))))))
337337
expect(match.matches[1]).toBe("x");
338338
expect(match.matches[2]).toBe("x");
339339
});
340-
xit("line: 72 - matches a?(ab|ba)* against 'ababababababababababababababababababababababababababababababababababababababababa'", () => {
340+
it("line: 72 - matches a?(ab|ba)* against 'ababababababababababababababababababababababababababababababababababababababababa'", () => {
341341
const match = exec(
342342
"a?(ab|ba)*",
343343
"ababababababababababababababababababababababababababababababababababababababababa",

spec/test-generator.js

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,28 +7,21 @@ const escape = (str) => str.replace("\\", "\\\\");
77

88
const knownIssues = {
99
"issue with parsing the test itself": [28, 58, 59, 78, 212, 213],
10-
"issue with generating the test": [61, 62, 64],
11-
"issue that require triage": [
12-
20,
10+
"issue with generating the test": [61, 62, 64, 76, 209, 210],
11+
"unsupported POSIX regex syntax": [54, 55, 56],
12+
"issue that require triage": [199, 202, 204, 205, 206, 207],
13+
// I can't find a good reference that describes this behaviour!
14+
"BUG: doesn't support anchors within capture groups": [20],
15+
// https://github.com/ColinEberhardt/assemblyscript-regex/issues/2
16+
"BUG: Should not return captured values for non-matching alternations": [
1317
35,
14-
72,
15-
76,
1618
133,
1719
150,
1820
187,
1921
188,
2022
190,
2123
191,
22-
199,
23-
202,
24-
204,
25-
205,
26-
206,
27-
207,
28-
209,
29-
210,
3024
],
31-
"unsupported POSIX regex syntax": [54, 55, 56],
3225
};
3326

3427
const hasKnownIssue = (index) => {

ts/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ globalAny.log = console.log;
55

66
import { RegExp } from "../assembly/regexp";
77

8-
const regexObj = new RegExp("a+");
9-
const match = regexObj.exec("aa");
8+
const regexObj = new RegExp("^(([^!]+!)?([^!]+)|.+!([^!]+!)([^!]+))$");
9+
const match = regexObj.exec("foo!bar!bas");
1010

1111
console.log(match);

0 commit comments

Comments
 (0)