Fix the wrong setup in the override cache test #2904
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: pysa | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
jobs: | |
pysa: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Install Dependencies | |
run: | | |
pip install -r requirements.txt | |
sudo apt-get install ocaml ocaml-dune | |
- name: Setup OCaml | |
uses: avsm/setup-ocaml@v2 | |
with: | |
ocaml-compiler: 4.14.0 | |
- name: Setup opam switch | |
run: | | |
opam switch create 4.14.0 | |
echo "OPAM_SWITCH_PREFIX=$HOME/.opam/4.14.0" >> $GITHUB_ENV | |
echo "CAML_LD_LIBRARY_PATH=$HOME/.opam/4.14.0/lib/stublibs:$HOME/.opam/4.14.0/lib/ocaml/stublibs:$HOME/.opam/4.14.0/lib/ocam" >> $GITHUB_ENV | |
echo "$HOME/.opam/4.14.0/bin" >> $GITHUB_PATH | |
echo "/home/opam/.opam/4.14.0/bin" >> $GITHUB_PATH | |
- name: Build Pyre (and Pysa) | |
run: | | |
./scripts/setup.sh --local --no-tests | |
make -C source | |
echo "PYTHONPATH=$GITHUB_WORKSPACE/..:$PYTHONPATH" >> $GITHUB_ENV | |
echo "pythonLocation=$GITHUB_WORKSPACE:$pythonLocation" >> $GITHUB_ENV | |
echo "PYRE_BINARY=$GITHUB_WORKSPACE/source/_build/default/main.exe" >> $GITHUB_ENV | |
echo "PYRE_TYPESHED=$GITHUB_WORKSPACE/stubs/typeshed/typeshed/" >> $GITHUB_ENV | |
- name: Run and test pysa output | |
run: | | |
cd ./documentation/deliberately_vulnerable_flask_app | |
. ./setup.sh | |
./run_integration_tests.sh |