-
Notifications
You must be signed in to change notification settings - Fork 11
/
action.yml
121 lines (116 loc) · 4.39 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
name: "echidna-action"
description: "Run Echidna, the smart contract fuzzer"
branding:
icon: 'shield'
color: 'red'
inputs:
files:
description: "Solidity files to analyze"
required: true
contract:
description: "Contract to analyze"
required: false
config:
description: "Config file (CLI arguments override config options)"
required: false
format:
description: "Output format: json, text, none. Disables interactive UI"
required: false
corpus-dir:
description: "Directory to store corpus and coverage data"
required: false
test-mode:
description: "Type of tests to be performed"
required: false
multi-abi:
description: "Use multi-abi mode of testing"
required: false
test-limit:
description: "Number of sequences of transactions to generate during testing"
required: false
shrink-limit:
description: "Number of tries to attempt to shrink a failing sequence of transactions"
required: false
seq-len:
description: "Number of transactions to generate during testing"
required: false
contract-addr:
description: "Address to deploy the contract to test"
required: false
deployer:
description: "Address of the deployer of the contract to test"
required: false
sender:
description: "Addresses to use for the transactions sent during testing"
required: false
seed:
description: "Run with a specific seed"
required: false
crytic-args:
description: "Additional arguments to use in crytic-compile for the compilation of the contract to test"
required: false
solc-args:
description: "Additional arguments to use in solc for the compilation of the contract to test"
required: false
solc-version:
description: "Version of the Solidity compiler to use"
required: false
output-file:
description: "Capture echidna's output into this file. The path must be relative to the repository root."
required: false
negate-exit-status:
description: "Apply logical NOT to echidna-test's exit status (for testing the action)"
required: false
echidna-version:
description: "Version of the Echidna Docker image to use"
required: false
default: latest
echidna-workdir:
description: "Path to run echidna-test from. Note that `files` and `config` are relative to this path"
required: false
internal-github-workspace:
# Do not set manually. This is a hacky way to pass the host workspace to inside the action
# This is used to improve compatibility when using ignore-compile.
# GitHub rewrites the argument if it is passed directly, to we use toJSON to "transform"
# it and avoid the remapping done by GitHub Actions.
default: ${{ toJSON(github.workspace) }}
outputs:
output-file:
description: "If produced, the file containing echidna-test's output, relative to the repository root."
value: ${{ steps.echidna.outputs.output-file }}
runs:
using: "composite"
steps:
- run: |
# echidna-action Docker container build
docker build -t echidna-action-image:$ECHIDNA_TAG --build-arg ECHIDNA_TAG ${{ github.action_path }}
shell: bash
env:
ECHIDNA_TAG: ${{ inputs.echidna-version }}
- id: echidna
run: |
# echidna campaign
${{ github.action_path }}/launch.sh echidna-action-image:${{ inputs.echidna-version }}
shell: bash
env:
INPUT_FILES: ${{ inputs.files }}
INPUT_CONTRACT: ${{ inputs.contract }}
INPUT_CONFIG: ${{ inputs.config }}
INPUT_FORMAT: ${{ inputs.format }}
INPUT_CORPUS-DIR: ${{ inputs.corpus-dir }}
INPUT_TEST-MODE: ${{ inputs.test-mode }}
INPUT_MULTI-ABI: ${{ inputs.multi-abi }}
INPUT_TEST-LIMIT: ${{ inputs.test-limit }}
INPUT_SHRINK-LIMIT: ${{ inputs.shrink-limit }}
INPUT_SEQ-LEN: ${{ inputs.seq-len }}
INPUT_CONTRACT-ADDR: ${{ inputs.contract-addr }}
INPUT_DEPLOYER: ${{ inputs.deployer }}
INPUT_SENDER: ${{ inputs.sender }}
INPUT_SEED: ${{ inputs.seed }}
INPUT_CRYTIC-ARGS: ${{ inputs.crytic-args }}
INPUT_SOLC-ARGS: ${{ inputs.solc-args }}
INPUT_SOLC-VERSION: ${{ inputs.solc-version }}
INPUT_OUTPUT-FILE: ${{ inputs.output-file }}
INPUT_NEGATE-EXIT-STATUS: ${{ inputs.negate-exit-status }}
INPUT_ECHIDNA-WORKDIR: ${{ inputs.echidna-workdir }}
INPUT_INTERNAL-GITHUB-WORKSPACE: ${{ inputs.internal-github-workspace }}