Show More
@@ -1,139 +1,139 b'' | |||||
1 | stages: |
|
1 | stages: | |
2 | - tests |
|
2 | - tests | |
3 |
|
3 | |||
4 | image: registry.heptapod.net/mercurial/ci-images/mercurial-core:$HG_CI_IMAGE_TAG |
|
4 | image: registry.heptapod.net/mercurial/ci-images/mercurial-core:$HG_CI_IMAGE_TAG | |
5 |
|
5 | |||
6 | variables: |
|
6 | variables: | |
7 | PYTHON: python |
|
7 | PYTHON: python | |
8 | TEST_HGMODULEPOLICY: "allow" |
|
8 | TEST_HGMODULEPOLICY: "allow" | |
9 | HG_CI_IMAGE_TAG: "v1.0" |
|
9 | HG_CI_IMAGE_TAG: "v1.0" | |
10 | TEST_HGTESTS_ALLOW_NETIO: "0" |
|
10 | TEST_HGTESTS_ALLOW_NETIO: "0" | |
11 |
|
11 | |||
12 | .all_template: &all |
|
12 | .all_template: &all | |
13 | when: on_success |
|
13 | when: on_success | |
14 |
|
14 | |||
15 | .runtests_template: &runtests |
|
15 | .runtests_template: &runtests | |
16 | <<: *all |
|
16 | <<: *all | |
17 | stage: tests |
|
17 | stage: tests | |
18 | # The runner made a clone as root. |
|
18 | # The runner made a clone as root. | |
19 | # We make a new clone owned by user used to run the step. |
|
19 | # We make a new clone owned by user used to run the step. | |
20 | before_script: |
|
20 | before_script: | |
21 | - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no |
|
21 | - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no | |
22 | - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'` |
|
22 | - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'` | |
23 | - cd /tmp/mercurial-ci/ |
|
23 | - cd /tmp/mercurial-ci/ | |
24 | - ls -1 tests/test-check-*.* > /tmp/check-tests.txt |
|
24 | - ls -1 tests/test-check-*.* > /tmp/check-tests.txt | |
25 | - black --version |
|
25 | - black --version | |
26 | - clang-format --version |
|
26 | - clang-format --version | |
27 | script: |
|
27 | script: | |
28 | - echo "python used, $PYTHON" |
|
28 | - echo "python used, $PYTHON" | |
29 | - echo "$RUNTEST_ARGS" |
|
29 | - echo "$RUNTEST_ARGS" | |
30 | - HGTESTS_ALLOW_NETIO="$TEST_HGTESTS_ALLOW_NETIO" HGMODULEPOLICY="$TEST_HGMODULEPOLICY" "$PYTHON" tests/run-tests.py --color=always $RUNTEST_ARGS |
|
30 | - HGTESTS_ALLOW_NETIO="$TEST_HGTESTS_ALLOW_NETIO" HGMODULEPOLICY="$TEST_HGMODULEPOLICY" "$PYTHON" tests/run-tests.py --color=always $RUNTEST_ARGS | |
31 |
|
31 | |||
32 | checks: |
|
32 | checks: | |
33 | <<: *runtests |
|
33 | <<: *runtests | |
34 | variables: |
|
34 | variables: | |
35 | RUNTEST_ARGS: "--time --test-list /tmp/check-tests.txt" |
|
35 | RUNTEST_ARGS: "--time --test-list /tmp/check-tests.txt" | |
36 | PYTHON: python3 |
|
36 | PYTHON: python3 | |
37 |
|
37 | |||
38 | rust-cargo-test: |
|
38 | rust-cargo-test: | |
39 | <<: *all |
|
39 | <<: *all | |
40 | stage: tests |
|
40 | stage: tests | |
41 | script: |
|
41 | script: | |
42 | - echo "python used, $PYTHON" |
|
42 | - echo "python used, $PYTHON" | |
43 | - make rust-tests |
|
43 | - make rust-tests | |
44 | variables: |
|
44 | variables: | |
45 | PYTHON: python3 |
|
45 | PYTHON: python3 | |
46 |
|
46 | |||
47 | test-c: |
|
47 | test-c: | |
48 | <<: *runtests |
|
48 | <<: *runtests | |
49 | variables: |
|
49 | variables: | |
50 | RUNTEST_ARGS: " --no-rust --blacklist /tmp/check-tests.txt" |
|
50 | RUNTEST_ARGS: " --no-rust --blacklist /tmp/check-tests.txt" | |
51 | PYTHON: python3 |
|
51 | PYTHON: python3 | |
52 | TEST_HGMODULEPOLICY: "c" |
|
52 | TEST_HGMODULEPOLICY: "c" | |
53 | TEST_HGTESTS_ALLOW_NETIO: "1" |
|
53 | TEST_HGTESTS_ALLOW_NETIO: "1" | |
54 |
|
54 | |||
55 | test-pure: |
|
55 | test-pure: | |
56 | <<: *runtests |
|
56 | <<: *runtests | |
57 | variables: |
|
57 | variables: | |
58 | RUNTEST_ARGS: "--pure --blacklist /tmp/check-tests.txt" |
|
58 | RUNTEST_ARGS: "--pure --blacklist /tmp/check-tests.txt" | |
59 | PYTHON: python3 |
|
59 | PYTHON: python3 | |
60 | TEST_HGMODULEPOLICY: "py" |
|
60 | TEST_HGMODULEPOLICY: "py" | |
61 |
|
61 | |||
62 | test-rust: |
|
62 | test-rust: | |
63 | <<: *runtests |
|
63 | <<: *runtests | |
64 | variables: |
|
64 | variables: | |
65 | HGWITHRUSTEXT: cpython |
|
65 | HGWITHRUSTEXT: cpython | |
66 | RUNTEST_ARGS: "--rust --blacklist /tmp/check-tests.txt" |
|
66 | RUNTEST_ARGS: "--rust --blacklist /tmp/check-tests.txt" | |
67 | PYTHON: python3 |
|
67 | PYTHON: python3 | |
68 | TEST_HGMODULEPOLICY: "rust+c" |
|
68 | TEST_HGMODULEPOLICY: "rust+c" | |
69 |
|
69 | |||
70 | test-rhg: |
|
70 | test-rhg: | |
71 | <<: *runtests |
|
71 | <<: *runtests | |
72 | variables: |
|
72 | variables: | |
73 | HGWITHRUSTEXT: cpython |
|
73 | HGWITHRUSTEXT: cpython | |
74 | RUNTEST_ARGS: "--rust --rhg --blacklist /tmp/check-tests.txt" |
|
74 | RUNTEST_ARGS: "--rust --rhg --blacklist /tmp/check-tests.txt" | |
75 | PYTHON: python3 |
|
75 | PYTHON: python3 | |
76 | TEST_HGMODULEPOLICY: "rust+c" |
|
76 | TEST_HGMODULEPOLICY: "rust+c" | |
77 |
|
77 | |||
78 | test-chg: |
|
78 | test-chg: | |
79 | <<: *runtests |
|
79 | <<: *runtests | |
80 | variables: |
|
80 | variables: | |
81 | PYTHON: python3 |
|
81 | PYTHON: python3 | |
82 | RUNTEST_ARGS: "--blacklist /tmp/check-tests.txt --chg" |
|
82 | RUNTEST_ARGS: "--blacklist /tmp/check-tests.txt --chg" | |
83 | TEST_HGMODULEPOLICY: "c" |
|
83 | TEST_HGMODULEPOLICY: "c" | |
84 |
|
84 | |||
85 | check-pytype: |
|
85 | check-pytype: | |
86 | extends: .runtests_template |
|
86 | extends: .runtests_template | |
87 | before_script: |
|
87 | before_script: | |
88 | - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no |
|
88 | - hg clone . /tmp/mercurial-ci/ --noupdate --config phases.publish=no | |
89 | - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'` |
|
89 | - hg -R /tmp/mercurial-ci/ update `hg log --rev '.' --template '{node}'` | |
90 | - cd /tmp/mercurial-ci/ |
|
90 | - cd /tmp/mercurial-ci/ | |
91 | - make local PYTHON=$PYTHON |
|
91 | - make local PYTHON=$PYTHON | |
92 | - $PYTHON -m pip install --user -U pytype==2021.04.15 |
|
92 | - $PYTHON -m pip install --user -U pytype==2021.04.15 | |
|
93 | script: | |||
|
94 | - echo "Entering script section" | |||
|
95 | - sh contrib/check-pytype.sh | |||
93 | variables: |
|
96 | variables: | |
94 | RUNTEST_ARGS: " --allow-slow-tests tests/test-check-pytype.t" |
|
|||
95 | HGTEST_SLOWTIMEOUT: "3600" |
|
|||
96 | PYTHON: python3 |
|
97 | PYTHON: python3 | |
97 | TEST_HGMODULEPOLICY: "c" |
|
|||
98 |
|
98 | |||
99 | # `sh.exe --login` sets a couple of extra environment variables that are defined |
|
99 | # `sh.exe --login` sets a couple of extra environment variables that are defined | |
100 | # in the MinGW shell, but switches CWD to /home/$username. The previous value |
|
100 | # in the MinGW shell, but switches CWD to /home/$username. The previous value | |
101 | # is stored in OLDPWD. Of the added variables, MSYSTEM is crucial to running |
|
101 | # is stored in OLDPWD. Of the added variables, MSYSTEM is crucial to running | |
102 | # run-tests.py- it is needed to make run-tests.py generate a `python3` script |
|
102 | # run-tests.py- it is needed to make run-tests.py generate a `python3` script | |
103 | # that satisfies the various shebang lines and delegates to `py -3`. |
|
103 | # that satisfies the various shebang lines and delegates to `py -3`. | |
104 | .window_runtests_template: &windows_runtests |
|
104 | .window_runtests_template: &windows_runtests | |
105 | <<: *all |
|
105 | <<: *all | |
106 | when: manual # we don't have any Windows runners anymore at the moment |
|
106 | when: manual # we don't have any Windows runners anymore at the moment | |
107 | stage: tests |
|
107 | stage: tests | |
108 | before_script: |
|
108 | before_script: | |
109 | - C:/MinGW/msys/1.0/bin/sh.exe --login -c 'cd "$OLDPWD" && ls -1 tests/test-check-*.* > C:/Temp/check-tests.txt' |
|
109 | - C:/MinGW/msys/1.0/bin/sh.exe --login -c 'cd "$OLDPWD" && ls -1 tests/test-check-*.* > C:/Temp/check-tests.txt' | |
110 | # TODO: find/install cvs, bzr, perforce, gpg, sqlite3 |
|
110 | # TODO: find/install cvs, bzr, perforce, gpg, sqlite3 | |
111 |
|
111 | |||
112 | script: |
|
112 | script: | |
113 | - echo "Entering script section" |
|
113 | - echo "Entering script section" | |
114 | - echo "python used, $Env:PYTHON" |
|
114 | - echo "python used, $Env:PYTHON" | |
115 | - Invoke-Expression "$Env:PYTHON -V" |
|
115 | - Invoke-Expression "$Env:PYTHON -V" | |
116 | - Invoke-Expression "$Env:PYTHON -m black --version" |
|
116 | - Invoke-Expression "$Env:PYTHON -m black --version" | |
117 | - echo "$Env:RUNTEST_ARGS" |
|
117 | - echo "$Env:RUNTEST_ARGS" | |
118 | - echo "$Env:TMP" |
|
118 | - echo "$Env:TMP" | |
119 | - echo "$Env:TEMP" |
|
119 | - echo "$Env:TEMP" | |
120 |
|
120 | |||
121 | - C:/MinGW/msys/1.0/bin/sh.exe --login -c 'cd "$OLDPWD" && HGTESTS_ALLOW_NETIO="$TEST_HGTESTS_ALLOW_NETIO" HGMODULEPOLICY="$TEST_HGMODULEPOLICY" $PYTHON tests/run-tests.py --color=always $RUNTEST_ARGS' |
|
121 | - C:/MinGW/msys/1.0/bin/sh.exe --login -c 'cd "$OLDPWD" && HGTESTS_ALLOW_NETIO="$TEST_HGTESTS_ALLOW_NETIO" HGMODULEPOLICY="$TEST_HGMODULEPOLICY" $PYTHON tests/run-tests.py --color=always $RUNTEST_ARGS' | |
122 |
|
122 | |||
123 | windows: |
|
123 | windows: | |
124 | <<: *windows_runtests |
|
124 | <<: *windows_runtests | |
125 | tags: |
|
125 | tags: | |
126 | - windows |
|
126 | - windows | |
127 | variables: |
|
127 | variables: | |
128 | TEST_HGMODULEPOLICY: "c" |
|
128 | TEST_HGMODULEPOLICY: "c" | |
129 | RUNTEST_ARGS: "--blacklist C:/Temp/check-tests.txt" |
|
129 | RUNTEST_ARGS: "--blacklist C:/Temp/check-tests.txt" | |
130 | PYTHON: py -3 |
|
130 | PYTHON: py -3 | |
131 |
|
131 | |||
132 | windows-pyox: |
|
132 | windows-pyox: | |
133 | <<: *windows_runtests |
|
133 | <<: *windows_runtests | |
134 | tags: |
|
134 | tags: | |
135 | - windows |
|
135 | - windows | |
136 | variables: |
|
136 | variables: | |
137 | TEST_HGMODULEPOLICY: "c" |
|
137 | TEST_HGMODULEPOLICY: "c" | |
138 | RUNTEST_ARGS: "--blacklist C:/Temp/check-tests.txt --pyoxidized" |
|
138 | RUNTEST_ARGS: "--blacklist C:/Temp/check-tests.txt --pyoxidized" | |
139 | PYTHON: py -3 |
|
139 | PYTHON: py -3 |
1 | NO CONTENT: file was removed |
|
NO CONTENT: file was removed |
General Comments 0
You need to be logged in to leave comments.
Login now