Skip to content

Commit

Permalink
[chore] Appveyor tests (#899)
Browse files Browse the repository at this point in the history
  • Loading branch information
rexxars authored and kristofferjs committed Sep 3, 2018
1 parent 5f990c7 commit a7cbfd2
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions appveyor.yml
@@ -0,0 +1,46 @@
environment:
matrix:
- nodejs_version: "10"
- nodejs_version: "8"
- nodejs_version: "6"

install:
- ps: Install-Product node $env:nodejs_version
- npm install
- npm run bootstrap
- npm run build

test_script:
- node --version
- npm --version

# Allow running the Sanity CLI tool without specifying absolute path
- set PATH=%PATH%;%APPVEYOR_BUILD_FOLDER%\packages\@sanity\bin

# Build CLI to a single file
- cd packages\@sanity\cli
- npm run pack
- npm i -g

# Remove source and dependencies from CLI to ensure it works standalone
- cd %APPVEYOR_BUILD_FOLDER%
- rd /s /q packages\@sanity\cli\node_modules
- rd /s /q packages\@sanity\cli\src
- rd /s /q packages\@sanity\cli\lib

# Test building the test studio with all customizations
- cd %APPVEYOR_BUILD_FOLDER%\packages\test-studio
- sanity build

# Test initializing a project in unattended mode
- mkdir %APPVEYOR_BUILD_FOLDER%\tmp
- sanity init -y --project=ppsg7ml5 --dataset=test --output-path=%APPVEYOR_BUILD_FOLDER%\tmp

# Use the newly commited changes instead of the latest dependencies from NPM
- cd %APPVEYOR_BUILD_FOLDER%\tmp
- node %APPVEYOR_BUILD_FOLDER%\scripts\symlinkDependencies.js .

# Test building the project with latest dependencies
- sanity build --skip-minify

build: off

0 comments on commit a7cbfd2

Please sign in to comment.