Skip to content

Commit

Permalink
Cache the restler binary and do not attempt to save cache if cache hit
Browse files Browse the repository at this point in the history
  • Loading branch information
iainsproat committed Jan 2, 2025
1 parent c00c3bb commit 5791e5a
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/rest-api-fuzzer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,34 @@ jobs:
run: |
pip install -r ${{ github.workspace }}/restler-fuzzer/restler/requirements.txt
- name: Restore cached Restler binaries
id: cache-restler-bin-restore
uses: actions/cache/restore@v4
with:
path: |
${{ github.workspace }}/bin/restler
key: restler-binaries-${{ env.RESTLER_VERSION }}

- name: Build RESTler
if: steps.cache-restler-bin-restore.outputs.cache-hit != 'true'
run: |
python ${{ github.workspace }}/restler-fuzzer/build-restler.py --dest_dir ${{ github.workspace }}/bin
python -m compileall -b /bin/restler
- name: Debug the built output
run: |
ls -la ${{ github.workspace }}/bin/restler
ls -la ${{ github.workspace }}/bin/restler/Restler
- name: Save Restler binaries to cache
if: steps.cache-restler-bin-restore.outputs.cache-hit != 'true'
id: cache-restler-bin-save
uses: actions/cache/save@v4
with:
path: |
${{ github.workspace }}/bin/restler
key: ${{ steps.cache-restler-bin-restore.outputs.cache-primary-key }}

- uses: actions/checkout@v4
name: Checkout speckle-server
with:
Expand Down Expand Up @@ -117,6 +136,7 @@ jobs:
cat ${{ github.workspace }}/restlerConfig/annotations.json
- name: Save Restler Config
if: steps.cache-config-restore.outputs.cache-hit != 'true'
id: cache-config-save
uses: actions/cache/save@v4
with:
Expand Down Expand Up @@ -145,6 +165,7 @@ jobs:
cat $(find ${{ github.workspace }}/Compile -type f -name "*.log") || true
- name: Save Grammar
if: steps.cache-grammar-restore.outputs.cache-hit != 'true'
id: cache-grammar-save
uses: actions/cache/save@v4
with:
Expand Down

0 comments on commit 5791e5a

Please sign in to comment.