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

Enabling demos tests with nightly binaries #68

Merged
merged 23 commits into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from 18 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
20 changes: 17 additions & 3 deletions .github/workflows/_basic-test.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
name: test-basics
on: [workflow_call, workflow_dispatch]
on:
workflow_call:
inputs:
nightly_binaries:
type: string
default: "false"
required: false
Dsantra92 marked this conversation as resolved.
Show resolved Hide resolved

jobs:
cpu:
Expand All @@ -20,9 +26,17 @@ jobs:
persist-credentials: false
submodules: "recursive"
fetch-depth: 1

- name: Checkout Ivy🛎
uses: actions/checkout@v4
with:
repository: unifyai/ivy
path: ivy
persist-credentials: false
submodules: "recursive"
fetch-depth: 1

- name: Run Integration testing for Basic Demos
id: tests
run: |
cd demos
docker run -v "$(pwd)":/ivy/demos unifyai/ivy:latest demos/tests/test_demos.sh ${{ secrets.USER_API_KEY }} learn_the_basics/${{ matrix.mods }}.ipynb
docker run -v "$(pwd)"/demos:/ivy/demos -v "$(pwd)"/ivy:/ivy/ivy unifyai/ivy:latest demos/tests/test_demos.sh ${{ secrets.USER_API_KEY }} learn_the_basics/${{ matrix.mods }}.ipynb ${{ inputs.nightly_binaries }}
20 changes: 17 additions & 3 deletions .github/workflows/_demo-test.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
name: test-examples
on: [workflow_call, workflow_dispatch]
on:
workflow_call:
inputs:
nightly_binaries:
type: string
default: "false"
required: false
vedpatwardhan marked this conversation as resolved.
Show resolved Hide resolved

jobs:
gpu:
Expand All @@ -23,7 +29,15 @@ jobs:
submodules: "recursive"
fetch-depth: 1

- name: Checkout Ivy🛎
uses: actions/checkout@v4
with:
repository: unifyai/ivy
path: ivy
persist-credentials: false
submodules: "recursive"
fetch-depth: 1

- name: Run Integration Tests for Enterprise Demos
run: |
cd demos
docker run --gpus all -v "$(pwd)":/ivy/demos unifyai/ivy:latest-gpu demos/tests/test_demos.sh ${{ secrets.USER_API_KEY }} examples_and_demos/${{ matrix.modules }}.ipynb
docker run --gpus all -v "$(pwd)"/demos:/ivy/demos -v "$(pwd)"/ivy:/ivy/ivy unifyai/ivy:latest-gpu demos/tests/test_demos.sh ${{ secrets.USER_API_KEY }} examples_and_demos/${{ matrix.modules }}.ipynb ${{ inputs.nightly_binaries }}
9 changes: 9 additions & 0 deletions .github/workflows/run-test-suite.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: E2E-QA-and-Deployment
on:
workflow_dispatch:
inputs:
nightly_binaries:
description: 'Testing with nightly binaries :'
vedpatwardhan marked this conversation as resolved.
Show resolved Hide resolved
default: "false"
required: false
push:
branches:
- 'main'
Expand Down Expand Up @@ -44,6 +49,8 @@ jobs:
name: examples-and-demos
uses: ./.github/workflows/_demo-test.yml
secrets: inherit
with:
nightly_binaries: ${{ github.event.inputs.nightly_binaries }}

stop-vm:
needs: run-test-example-demos
Expand Down Expand Up @@ -72,3 +79,5 @@ jobs:
name: learn-the-basics
uses: ./.github/workflows/_basic-test.yml
secrets: inherit
with:
nightly_binaries: ${{ github.event.inputs.nightly_binaries }}
8 changes: 6 additions & 2 deletions tests/test_demos.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
#!/bin/bash

if [ $3 == "true" ];
vedpatwardhan marked this conversation as resolved.
Show resolved Hide resolved
then
export VERSION=nightly
fi

cd ivy
pip install -e .

Expand All @@ -14,6 +19,5 @@ echo -n "$1" > .ivy/key.pem
pip install -r requirements.txt >/dev/null 2>&1

# run test
echo "PATH"
echo "$2"
echo "PATH : $2"
python3 tests/main.py "$2"
Loading