File tree 5 files changed +46
-17
lines changed
5 files changed +46
-17
lines changed Original file line number Diff line number Diff line change @@ -56,6 +56,9 @@ module.exports = {
56
56
"@eslint-community/mysticatea/ts/ban-ts-comment" : "off" ,
57
57
"@eslint-community/mysticatea/ts/no-unsafe-assignment" : "off" ,
58
58
"@eslint-community/mysticatea/ts/no-unsafe-call" : "off" ,
59
+ "@eslint-community/mysticatea/ts/naming-convention" : "off" ,
60
+ "@eslint-community/mysticatea/ts/no-require-imports" : "off" ,
61
+ "@eslint-community/mysticatea/ts/no-var-requires" : "off" ,
59
62
} ,
60
63
} ,
61
64
Original file line number Diff line number Diff line change 1
1
name : cron
2
2
on :
3
+ workflow_dispatch : null
3
4
schedule :
4
5
- cron : 0 0 * * 0
5
6
7
+ permissions :
8
+ contents : write
9
+ pull-requests : write
10
+
6
11
jobs :
7
- check-resource-update :
8
- name : check-resource-update
12
+ update-unicode-resource :
13
+ name : update-unicode-resource
9
14
runs-on : ubuntu-latest
10
15
steps :
11
16
- name : Checkout
@@ -18,12 +23,15 @@ jobs:
18
23
run : npm install
19
24
- name : Update
20
25
run : npm run update:unicode
21
- - name : Check changes
22
- run : |
23
- git add --all && \
24
- git diff-index --cached HEAD --stat --exit-code
25
- check-extract-test262 :
26
- name : check-extract-test262
26
+ - uses : peter-evans/create-pull-request@v6
27
+ with :
28
+ commit-message : " fix: updates unicode resource with latest"
29
+ branch : update-unicode-resource
30
+ branch-suffix : timestamp
31
+ title : " fix: updates unicode resource with latest"
32
+
33
+ update-test262 :
34
+ name : update-test262
27
35
runs-on : ubuntu-latest
28
36
steps :
29
37
- name : Checkout
36
44
run : npm install
37
45
- name : Update
38
46
run : npm run update:test262:extract
39
- - name : Check changes
40
- run : |
41
- git add --all && \
42
- git diff-index --cached HEAD --stat --exit-code
47
+ - uses : peter-evans/create-pull-request@v6
48
+ with :
49
+ commit-message : " test: updates test cases extracted from test262"
50
+ branch : update-test262
51
+ branch-suffix : timestamp
52
+ title : " test: updates test cases extracted from test262"
Original file line number Diff line number Diff line change 82
82
"rimraf" : " ^3.0.2" ,
83
83
"rollup" : " ^2.79.1" ,
84
84
"rollup-plugin-sourcemaps" : " ^0.6.3" ,
85
- "test262" : " git+https://github.com/tc39/test262.git" ,
86
- "test262-stream" : " ^1.4.0" ,
87
85
"ts-node" : " ^10.9.1" ,
88
86
"typescript" : " ~5.0.2"
89
87
},
Original file line number Diff line number Diff line change 1
- // @ts -ignore -- ignore
2
- import TestStream from "test262-stream"
3
1
import path from "path"
4
2
import { promises as fs } from "fs"
5
3
import { parseRegExpLiteral } from "../src/index"
@@ -8,6 +6,16 @@ import { cloneWithoutCircular } from "./clone-without-circular"
8
6
import type { RegExpSyntaxError } from "../src/regexp-syntax-error"
9
7
import { fixturesData } from "../test/fixtures/parser/literal"
10
8
import type { Readable } from "stream"
9
+ import { execSync } from "child_process"
10
+
11
+ console . log ( "Installing test262 and test262-stream..." )
12
+
13
+ execSync (
14
+ "npm install --no-save git+https://github.com/tc39/test262.git test262-stream" ,
15
+ { stdio : "inherit" } ,
16
+ )
17
+
18
+ console . log ( "Extracting test262 fixtures..." )
11
19
12
20
const fixturesRoot = path . join (
13
21
__dirname ,
@@ -16,6 +24,8 @@ const fixturesRoot = path.join(
16
24
17
25
const test262Root = path . dirname ( require . resolve ( "test262/package.json" ) )
18
26
27
+ const TestStream = require ( "test262-stream" )
28
+
19
29
const stream : Readable = new TestStream ( test262Root , { omitRuntime : true } )
20
30
21
31
type Test = {
Original file line number Diff line number Diff line change @@ -49,13 +49,21 @@ const DATA_SOURCES = [
49
49
scValues : getLatestUnicodeScriptValues ,
50
50
} ,
51
51
{
52
- url : "https://tc39.es/ecma262/multipage/text-processing.html" ,
52
+ url : "https://tc39.es/ecma262/2024/ multipage/text-processing.html" ,
53
53
version : 2024 ,
54
54
binProperties : "#table-binary-unicode-properties" ,
55
55
gcValues : getLatestUnicodeGeneralCategoryValues ,
56
56
scValues : getLatestUnicodeScriptValues ,
57
57
binPropertiesOfStrings : "#table-binary-unicode-properties-of-strings" ,
58
58
} ,
59
+ {
60
+ url : "https://tc39.es/ecma262/multipage/text-processing.html" ,
61
+ version : 2025 ,
62
+ binProperties : "#table-binary-unicode-properties" ,
63
+ gcValues : getLatestUnicodeGeneralCategoryValues ,
64
+ scValues : getLatestUnicodeScriptValues ,
65
+ binPropertiesOfStrings : "#table-binary-unicode-properties-of-strings" ,
66
+ } ,
59
67
]
60
68
const FILE_PATH = "src/unicode/properties.ts"
61
69
const logger = console
You can’t perform that action at this time.
0 commit comments