Skip to content

Commit 2ab1a1d

Browse files
committed
Merge branch 'main' into feat/mutation-testing
2 parents 75402ba + 345ae46 commit 2ab1a1d

File tree

197 files changed

+1590
-5078
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

197 files changed

+1590
-5078
lines changed

.github/workflows/eth-integration.yml .github/workflows/base-oracle-integration.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
name: Foundry eth integration tests
1+
name: Foundry base chainlink oracle integration tests
22

33
on: [pull_request]
44

55
env:
6-
ETH_RPC_URL: ${{secrets.ETH_RPC_URL}}
6+
BASE_RPC_URL: ${{secrets.BASE_RPC_URL}}
77

88
jobs:
99
run-eth-mainnet-tests:
10-
name: eth-mainnet-integration-tests
10+
name: base-oracle-integration-tests
1111
runs-on: ubuntu-latest
1212

1313
steps:
@@ -20,4 +20,4 @@ jobs:
2020
uses: ./.github/actions
2121

2222
- name: Integration Test Contracts
23-
run: time forge test --match-contract IntegrationTest --fork-url $ETH_RPC_URL
23+
run: time forge test --match-contract ChainlinkCompositeOracleIntegrationTestBase --fork-url $BASE_RPC_URL

.github/workflows/invariant.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ jobs:
1717
uses: ./.github/actions
1818

1919
- name: Invariant Test Contracts
20-
run: time forge test -vvv --match-contract InvariantTest
20+
run: time forge test -vvv --match-contract xWELLOwnerHandler

.github/workflows/lint.yml

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Linter
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
lint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: "Check out the repo"
10+
uses: actions/checkout@v3
11+
with:
12+
submodules: recursive
13+
14+
- name: "Install Node.js"
15+
uses: actions/setup-node@v3
16+
with:
17+
node-version: lts/*
18+
19+
- name: "Install the Node.js dependencies"
20+
run: npm install
21+
22+
- name: Run linter and check for errors
23+
id: lint
24+
run: |
25+
LINT_OUTCOME=$(npm run lint 2>&1 || true) # Prevent the step from failing immediately
26+
echo "$LINT_OUTCOME"
27+
echo "LINT_OUTCOME<<EOF" >> $GITHUB_ENV
28+
echo "$LINT_OUTCOME" >> $GITHUB_ENV
29+
echo "EOF" >> $GITHUB_ENV
30+
if echo "$LINT_OUTCOME" | grep -q " error "; then
31+
echo "## Lint result" >> $GITHUB_STEP_SUMMARY
32+
echo "❌ Failed due to errors" >> $GITHUB_STEP_SUMMARY
33+
exit 1
34+
else
35+
echo "## Lint result" >> $GITHUB_STEP_SUMMARY
36+
echo "✅ Passed or warnings found" >> $GITHUB_STEP_SUMMARY
37+
fi

.husky/.pre-commit.sh

+6-6
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ STAGED_SOL_FILES=$(mktemp)
55
# Temporary file to hold list of all staged files for prettier
66
STAGED_FILES=$(mktemp)
77

8-
# List staged .sol files
9-
git diff --cached --name-only -- '*.sol' > "$STAGED_SOL_FILES"
10-
# List all staged files
11-
git diff --cached --name-only > "$STAGED_FILES"
8+
# List staged .sol files ignoring deleted and renamed files
9+
git diff --cached --name-status -- '*.sol' | grep -v '^(D|R[0-9]+)' | cut -f2- > "$STAGED_SOL_FILES"
10+
# List all staged files ignoring deleted and renamed files
11+
git diff --cached --name-status | grep -v '^(D|R[0-9]+)' | cut -f2- > "$STAGED_FILES"
1212

1313
# Run Solhint on staged .sol files, if any
1414
if [ -s "$STAGED_SOL_FILES" ]; then
1515
# If there are staged .sol files, run Solhint on them
16-
SOLHINT_OUTPUT=$(cat "$STAGED_SOL_FILES" | xargs npx solhint --config ./.solhintrc --ignore-path .solhintignore)
16+
SOLHINT_OUTPUT=$(cat "$STAGED_SOL_FILES" | xargs npm run lint)
1717
SOLHINT_EXIT_CODE=$?
1818

1919
if [ $SOLHINT_EXIT_CODE -ne 0 ]; then
@@ -30,7 +30,7 @@ fi
3030
# Run Prettier and check for errors on staged files
3131
if [ -s "$STAGED_FILES" ]; then
3232
# Note: Using `--write` with Prettier to automatically fix formatting
33-
PRETTIER_OUTPUT=$(cat "$STAGED_FILES" | xargs npx prettier --ignore-path .prettierignore --write)
33+
PRETTIER_OUTPUT=$(cat "$STAGED_FILES" | xargs npm run prettier)
3434
PRETTIER_EXIT_CODE=$?
3535

3636
if [ $PRETTIER_EXIT_CODE -ne 0 ]; then

.solhintrc

+3-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"not-rely-on-time": "off",
1010
"one-contract-per-file": "off",
1111
"no-inline-assembly": "off",
12-
"custom-errors": "off",
12+
"gas-custom-errors": "off",
1313
"no-empty-blocks": "off",
1414
"var-name-mixedcase": "off",
1515
"no-global-import": "off",
@@ -22,6 +22,7 @@
2222
"const-name-snakecase": "off",
2323
"visibility-modifier-order": "off",
2424
"max-states-count": "off",
25-
"no-complex-fallback": "off"
25+
"no-complex-fallback": "off",
26+
"no-unused-import": "error"
2627
}
2728
}

CROSSCONTRACTINTERACTION.md

-15
This file was deleted.

MARKET_ADD.md

-141
This file was deleted.

0 commit comments

Comments
 (0)