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

Restore windows CI #816

Merged
merged 7 commits into from
May 30, 2024
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
2 changes: 1 addition & 1 deletion .github/workflows/example_data_cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
fail-fast: false
matrix:
python-version: ["3.12"]
os: [ubuntu-latest, macos-latest, macos-13] #, windows-latest]
os: [ubuntu-latest, macos-latest, macos-13, windows-latest]

steps:

Expand Down
27 changes: 6 additions & 21 deletions .github/workflows/testing_pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ jobs:
- os: macos-13 # Mac x64 runner
label: environments/environment-MAC-intel.yml

# - os: windows-latest
# label: environments/environment-Windows.yml
- os: windows-latest
label: environments/environment-Windows.yml


steps:
Expand Down Expand Up @@ -95,33 +95,18 @@ jobs:
path: ./behavior_testing_data
key: behavior-datasets-${{ matrix.os }}-${{ steps.behavior.outputs.HASH_behavior_DATASET }}

- name: Save working directory to environment file
run: echo "GIN_DATA_DIR=$(pwd)" >> .env
if: runner.os != 'Windows'

- name: Save working directory to environment file (Windows)
run: echo GIN_DATA_DIR=%cd% >> .env
shell: bash
if: runner.os == 'Windows'

# Display environment file for debugging
- name: Print environment file
run: cat .env
if: runner.os != 'Windows'

- name: Print environment file
run: type .env
shell: bash
if: runner.os == 'Windows'

# Run pipeline tests
- if: matrix.os != 'ubuntu-latest'
name: Run tests
run: npm run test:pipelines
env:
GIN_DATA_DIRECTORY: ${{ github.workspace }}
Comment on lines +102 to +103
Copy link
Collaborator Author

@CodyCBakerPhD CodyCBakerPhD May 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ohhh, I had no idea these were (or could be) scoped per line under run/steps


- if: matrix.os == 'ubuntu-latest'
name: Run tests with xvfb
run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- npm run test:pipelines
env:
GIN_DATA_DIRECTORY: ${{ github.workspace }}

- name: Archive Pipeline Test Screenshots
if: always()
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/pipelines.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { sleep } from '../puppeteer';


// NOTE: We assume the user has put the GIN data in ~/NWB_GUIDE/test-data/GIN
const testGINPath = process.env.GIN_DATA_DIR ?? join(homedir(), paths.root, 'test-data', 'GIN')
const testGINPath = process.env.GIN_DATA_DIRECTORY ?? join(homedir(), paths.root, 'test-data', 'GIN')
console.log('Using test GIN data at:', testGINPath)

const pipelineDescribeFn = existsSync(testGINPath) ? describe : describe.skip
Expand Down
Loading