* Functional tests setup for the LSP server * Add nix derivation for lsp-test-0.6.1.0 * Register fixture files * Enable functional tests on appveyor * Attempt to fix Position errors * Fix `dhall-lsp-server` to specify a UTF8 locale Related to https://github.com/dhall-lang/dhall-haskell/issues/1356#issuecomment-536840612 * Specify utf8 encoding for tests * Add test for hovering functionality * Add glob to list fixture files * Remove extra do
92 lines
2.8 KiB
YAML
92 lines
2.8 KiB
YAML
version: 1.0.{build}
|
|
|
|
branches:
|
|
only:
|
|
- master
|
|
- /.*appveyor.*/
|
|
- /\d*\.\d*\.\d*/
|
|
|
|
environment:
|
|
STACK_ROOT: C:\sr
|
|
STACK_VERSION: 1.9.3
|
|
# Override the temp directory to avoid sed escaping issues
|
|
# See https://github.com/haskell/cabal/issues/5386
|
|
TMP: c:\tmp
|
|
LANG: en_US.UTF-8
|
|
|
|
matrix:
|
|
- STACK_YAML: stack.yaml
|
|
- STACK_YAML: stack-lts-6.yaml
|
|
|
|
install:
|
|
- choco install -y haskell-stack --version %STACK_VERSION%
|
|
- stack setup > nul
|
|
- cd %APPVEYOR_BUILD_FOLDER%
|
|
- git submodule update --init --recursive
|
|
|
|
cache:
|
|
- '%STACK_ROOT% -> %STACK_YAML%, appveyor.yml'
|
|
- '.stack-work -> %STACK_YAML%, appveyor.yml'
|
|
- 'dhall/.stack-work -> %STACK_YAML%, appveyor.yml'
|
|
- 'dhall-bash/.stack-work -> %STACK_YAML%, appveyor.yml'
|
|
|
|
for:
|
|
-
|
|
matrix:
|
|
except:
|
|
- STACK_YAML: stack-lts-6.yaml
|
|
|
|
build_script:
|
|
- stack build
|
|
- stack install --local-bin-path bin
|
|
- if /I "%APPVEYOR_REPO_TAG%" EQU "true" (set DEPLOY_TAG=%APPVEYOR_REPO_TAG_NAME%-x86_64-windows.zip)
|
|
- set DEPLOY_DIR=%APPVEYOR_BUILD_FOLDER%\bin
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-json.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-yaml.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\json-to-dhall.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\yaml-to-dhall.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-bash-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-bash.exe")
|
|
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-lsp-server-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-lsp-server.exe")
|
|
|
|
test_script:
|
|
# chcp 65001 (utf-8) needed to make doctest work
|
|
- chcp 65001 && stack test dhall
|
|
- stack test dhall-json
|
|
- stack test dhall-bash
|
|
# - stack test dhall-lsp-server:doctest # Disabled while the tests are broken.
|
|
- stack test dhall-lsp-server:tests
|
|
- stack bench dhall --benchmark-arguments "--quick --min-duration=0 --include-first-iter"
|
|
|
|
-
|
|
matrix:
|
|
only:
|
|
- STACK_YAML: stack-lts-6.yaml
|
|
|
|
build_script:
|
|
- stack build
|
|
- stack install --local-bin-path bin
|
|
|
|
test_script:
|
|
# chcp 65001 (utf-8) needed to make doctest work
|
|
- chcp 65001 && stack test dhall
|
|
|
|
artifacts:
|
|
- path: bin\dhall-%DEPLOY_TAG%
|
|
name: dhall
|
|
- path: bin\dhall-json-%DEPLOY_TAG%
|
|
name: dhall-json
|
|
- path: bin\dhall-bash-%DEPLOY_TAG%
|
|
name: dhall-bash
|
|
- path: bin\dhall-lsp-server-%DEPLOY_TAG%
|
|
name: dhall-lsp-server
|
|
|
|
deploy:
|
|
- provider: GitHub
|
|
auth_token:
|
|
secure: Gs/tiz6Jtg/Zjd4zGHDhuSv4Y9a+zJ574LWwzOe2bvZNGX/M8XupkxdGmBpDlnOf
|
|
artifact: dhall, dhall-json, dhall-bash, dhall-lsp-server
|
|
on:
|
|
APPVEYOR_REPO_TAG: true
|
|
STACK_YAML: stack.yaml
|