Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: Add initial version #2

Merged
merged 9 commits into from
Sep 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: CI

on:
push:
branches:
- main
tags:
- 'v*'
pull_request:
branches:
- main

env:
MACOSX_DEPLOYMENT_TARGET: 12.0

jobs:
Build:
name: Conda-Forge LPython Test ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: ["windows-2019", "macos-latest", "ubuntu-latest"]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: mamba-org/setup-micromamba@v1
with:
environment-file: environment.yml

- uses: hendrikmuhs/ccache-action@main
with:
variant: sccache
key: ${{ github.job }}-${{ matrix.os }}

- name: Clone LPython Source Repository
shell: bash -e -l {0}
run: |
mkdir ~/.ssh
chmod 700 ~/.ssh
ssh-keyscan github.com >> ~/.ssh/known_hosts
eval "$(ssh-agent -s)"

git clone git@github.com:lcompilers/lpython.git
git fetch --tags -f
git checkout v0.20.0

- name: Run LPython Ctest
shell: bash -e -l {0}
run: |
cd lpython
ctest

- name: Run LPython Integration Tests
shell: bash -e -l {0}
run: |
cd lpython/integration_tests
./run_tests.py -b llvm c wasm

- name: Run LPython Fast Integration Tests
shell: bash -e -l {0}
run: |
cd lpython/integration_tests
./run_tests.py -b llvm c wasm -f

- name: Run LPython Reference Tests
shell: bash -e -l {0}
run: |
cd lpython
./run_tests.py
9 changes: 9 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: lf
channels:
- conda-forge
dependencies:
- python=3.10
- lpython=0.20.0
- nodejs=18.12.1
- make=4.3
- cmake=3.25.2