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
# if there are any added or changed (excluding staged) files then list them and fail
112
+
cd ${{ inputs.cwd }}
113
+
if ! git diff --quiet || [[ -n "$(git ls-files --others --exclude-standard)" ]]; then
114
+
git status --short
115
+
git diff | head -100
116
+
echo "Git repo has changed, either correctly fix those files locally or .gitignore them"; exit 1;
117
+
fi
118
+
id: git-diffs
119
+
120
+
- name: Check some wtf's
121
+
shell: bash
122
+
run: |
123
+
# if the package.json file has a wtf script, run it
124
+
# if it returns anything, print it then fail the action
125
+
cd ${{ inputs.cwd }}
126
+
if jq -e '.scripts.wtf' package.json >/dev/null; then
127
+
out=$(yarn wtf)
128
+
echo "$out"
129
+
if [ -n "$out" ]; then
130
+
echo "wt(actual)f: issues detected by running 'yarn wtf' (which is an optional script in package.json used to detect project bespoke issues)"
131
+
exit 1
132
+
fi
133
+
echo "wtf: no issues detected by running 'yarn wtf' (which is an optional script in package.json used to detect project bespoke issues)"
134
+
fi
135
+
echo "wtf: no script "wtf" in package.json, which is fine and dandy as 'yarn wtf' is an optional script in package.json used to detect project bespoke issues"
# - name: Run Forge build, generating contract sizes reports into the regression folder - if they differ from the ones in the repo, they will be failed in the git-diffs step
104
-
# if: runner.os != 'Windows' # TODO: for some reason, the sizes processing doesn't work on windows
105
-
# shell: bash
106
-
# run: |
107
-
# # generate contract sizes reports into the regression folder - if they differ from the ones in the repo, they will be failed in the git-diffs step
108
-
# cd ${{ inputs.cwd }}
109
-
# uv run yarn sizes
110
-
# id: sizes
111
-
112
-
- name: Run Forge tests
113
-
shell: bash
114
-
run: |
115
-
# run all the foundry tests in the test folder
116
-
cd ${{ inputs.cwd }}
117
-
yarn test
118
-
id: test
119
-
120
-
- name: Run Lint on Forge tests
121
-
shell: bash
122
-
run: |
123
-
# run all the foundry tests in the test folder
124
-
cd ${{ inputs.cwd }}
125
-
yarn lint:test
126
-
id: lint-test
127
-
128
-
# - name: Run Forge tests - coverage
129
-
# if: runner.os != 'Windows' # TODO: for some reason, the coverage processing doesn't work on windows
130
-
# shell: bash
131
-
# run: |
132
-
# # generate coverage reports into the regression folder - if they differ from the ones in the repo, they will be failed in the git-diffs step
133
-
# cd ${{ inputs.cwd }}
134
-
# uv run yarn coverage
135
-
# id: coverage
136
-
137
-
# - name: Run Forge tests - gas
138
-
# if: runner.os != 'Windows' # TODO: for some reason, the gas processing doesn't work on windows
139
-
# shell: bash
140
-
# run: |
141
-
# # generate gas reports into the regression folder - if they differ from the ones in the repo, they will be failed in the git-diffs step
142
-
# cd ${{ inputs.cwd }}
143
-
# uv run yarn gas
144
-
# id: gas
145
-
146
-
# - name: Run upgradeable contract deployment validation
147
-
# shell: bash
148
-
# run: |
149
-
# # check all contracts for deployment upgradeability
150
-
# cd ${{ inputs.cwd }}
151
-
# uv run yarn validate
152
-
# id: validate
153
-
154
-
- name: Run bytecode generation for the factory
155
-
shell: bash
156
-
run: |
157
-
cd ${{ inputs.cwd }}
158
-
yarn extract
159
-
id: validate
160
-
161
-
- name: Check for changed repo files
162
-
shell: bash
163
-
run: |
164
-
# if there are any added or changed (excluding staged) files then list them and fail
165
-
cd ${{ inputs.cwd }}
166
-
if ! git diff --quiet || [[ -n "$(git ls-files --others --exclude-standard)" ]]; then
167
-
git status --short
168
-
git diff | head -100
169
-
echo "Git repo has changed, either correctly fix those files locally or .gitignore them"; exit 1;
170
-
fi
171
-
id: git-diffs
172
-
173
-
- name: Check some wtf's
174
-
shell: bash
175
-
run: |
176
-
# if the package.json file has a wtf script, run it
177
-
# if it returns anything, print it then fail the action
178
-
cd ${{ inputs.cwd }}
179
-
if jq -e '.scripts.wtf' package.json >/dev/null; then
180
-
out=$(yarn wtf)
181
-
echo "$out"
182
-
if [ -n "$out" ]; then
183
-
echo "wt(actual)f: issues detected by running 'yarn wtf' (which is an optional script in package.json used to detect project bespoke issues)"
184
-
exit 1
185
-
fi
186
-
echo "wtf: no issues detected by running 'yarn wtf' (which is an optional script in package.json used to detect project bespoke issues)"
187
-
fi
188
-
echo "wtf: no script "wtf" in package.json, which is fine and dandy as 'yarn wtf' is an optional script in package.json used to detect project bespoke issues"
0 commit comments