2016-07-28 00:34:00 +00:00
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
- master
|
|
|
|
|
|
|
|
os: Visual Studio 2015
|
|
|
|
|
2017-04-24 17:04:34 +00:00
|
|
|
environment:
|
2017-08-01 15:34:00 +00:00
|
|
|
|
|
|
|
global:
|
|
|
|
# Workaround for https://github.com/conda/conda-build/issues/636
|
|
|
|
PYTHONIOENCODING: UTF-8
|
|
|
|
CONDA_INSTALL_LOCN: "C:\\Miniconda35-x64"
|
2019-12-23 20:13:48 +00:00
|
|
|
CMAKE_OPTIONS: ""
|
|
|
|
CPP_TEST_OPTIONS: ""
|
2017-08-01 15:34:00 +00:00
|
|
|
|
2017-04-24 17:04:34 +00:00
|
|
|
matrix:
|
|
|
|
- CMAKE_VS_VERSION: "10 2010"
|
2019-12-23 20:13:48 +00:00
|
|
|
CMAKE_OPTIONS: "-DFLATBUFFERS_BUILD_LEGACY=1"
|
|
|
|
CPP_TEST_OPTIONS: "--std-cpp c++0x"
|
2019-01-07 18:04:44 +00:00
|
|
|
MONSTER_EXTRA: "skip"
|
|
|
|
|
2018-08-16 19:17:52 +00:00
|
|
|
- CMAKE_VS_VERSION: "12 2013"
|
2019-01-07 18:04:44 +00:00
|
|
|
MONSTER_EXTRA: "skip"
|
|
|
|
|
2017-04-24 17:04:34 +00:00
|
|
|
- CMAKE_VS_VERSION: "14 2015"
|
2019-01-07 18:04:44 +00:00
|
|
|
MONSTER_EXTRA: ""
|
2017-04-24 17:04:34 +00:00
|
|
|
|
2016-07-28 00:34:00 +00:00
|
|
|
platform:
|
|
|
|
- x86
|
|
|
|
- x64
|
|
|
|
|
|
|
|
configuration:
|
|
|
|
- Debug
|
|
|
|
- Release
|
|
|
|
|
|
|
|
before_build:
|
2019-01-07 18:04:44 +00:00
|
|
|
- set MONSTER_EXTRA=%MONSTER_EXTRA%
|
2019-12-23 20:13:48 +00:00
|
|
|
- cmake . -G"Visual Studio %CMAKE_VS_VERSION%" -DFLATBUFFERS_CODE_SANITIZE=1 %CMAKE_OPTIONS%
|
2016-12-12 23:43:49 +00:00
|
|
|
# This cuts down on a lot of noise generated by xamarin warnings.
|
|
|
|
- del "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
|
2016-07-28 00:34:00 +00:00
|
|
|
|
|
|
|
build:
|
|
|
|
project: ALL_BUILD.vcxproj
|
2016-12-12 23:43:49 +00:00
|
|
|
verbosity: minimal
|
2016-07-28 00:34:00 +00:00
|
|
|
|
2018-08-16 19:17:52 +00:00
|
|
|
after_build:
|
|
|
|
- python conan/appveyor/install.py
|
|
|
|
- python conan/appveyor/build.py
|
|
|
|
|
2017-08-01 15:34:00 +00:00
|
|
|
install:
|
|
|
|
- set PATH=%CONDA_INSTALL_LOCN%;%CONDA_INSTALL_LOCN%\scripts;%PATH%;
|
2018-09-12 18:44:51 +00:00
|
|
|
- curl -sSf -o rustup-init.exe https://win.rustup.rs/
|
|
|
|
- rustup-init.exe -y
|
|
|
|
- set PATH=%PATH%;C:\Users\appveyor\.cargo\bin
|
|
|
|
- rustc -V
|
|
|
|
- cargo -V
|
2017-08-01 15:34:00 +00:00
|
|
|
|
2016-12-12 23:43:49 +00:00
|
|
|
test_script:
|
2018-10-22 22:41:12 +00:00
|
|
|
- call .appveyor\check-generate-code.bat -b %CONFIGURATION%
|
2017-08-01 15:34:00 +00:00
|
|
|
- "cd tests"
|
|
|
|
- rem "Building all code"
|
2019-12-23 20:13:48 +00:00
|
|
|
- generate_code.bat -b %CONFIGURATION% %CPP_TEST_OPTIONS%
|
2017-08-01 15:34:00 +00:00
|
|
|
- 7z a GeneratedMyGameCode.zip MyGame\
|
2016-12-12 23:43:49 +00:00
|
|
|
- rem "---------------- C++ -----------------"
|
2017-08-01 15:34:00 +00:00
|
|
|
- "cd .."
|
2016-12-12 23:43:49 +00:00
|
|
|
- "%CONFIGURATION%\\flattests.exe"
|
|
|
|
- "cd tests"
|
2017-08-01 15:34:00 +00:00
|
|
|
- rem "---------------- Java -----------------"
|
2016-12-12 23:43:49 +00:00
|
|
|
- "java -version"
|
|
|
|
- "JavaTest.bat"
|
2018-09-12 18:44:51 +00:00
|
|
|
- rem "---------------- Rust ----------------"
|
|
|
|
- "RustTest.bat"
|
2016-12-12 23:43:49 +00:00
|
|
|
- rem "---------------- JS -----------------"
|
|
|
|
- "node --version"
|
2017-05-24 22:21:26 +00:00
|
|
|
- "..\\%CONFIGURATION%\\flatc -b -I include_test monster_test.fbs unicode_test.json"
|
2017-04-21 16:29:42 +00:00
|
|
|
- "node JavaScriptTest ./monster_test_generated"
|
2017-08-01 15:34:00 +00:00
|
|
|
- rem "-------------- Python ---------------"
|
|
|
|
- where python
|
|
|
|
- python --version
|
|
|
|
- where pip
|
|
|
|
- pip --version
|
|
|
|
- where conda
|
|
|
|
- conda --version
|
|
|
|
- rem "installing flatbuffers python library"
|
|
|
|
- pip install ../python
|
|
|
|
- rem "testing without installing Numpy"
|
|
|
|
- python py_test.py 0 0 0
|
2017-08-24 20:46:46 +00:00
|
|
|
- rem "testing after installing Numpy - disabled"
|
|
|
|
# FIXME: This has a LOT of unnecessary dependencies and makes the tests fail
|
|
|
|
# with timeouts.
|
|
|
|
# - conda install --yes numpy
|
|
|
|
# - python py_test.py 0 0 0
|
2016-12-12 23:43:49 +00:00
|
|
|
- rem "---------------- C# -----------------"
|
|
|
|
# Have to compile this here rather than in "build" above because AppVeyor only
|
|
|
|
# supports building one project??
|
|
|
|
- "cd FlatBuffers.Test"
|
|
|
|
- "msbuild.exe /property:Configuration=Release;OutputPath=tempcs /verbosity:minimal FlatBuffers.Test.csproj"
|
|
|
|
- "tempcs\\FlatBuffers.Test.exe"
|
2019-02-21 22:36:55 +00:00
|
|
|
# Run tests with UNSAFE_BYTEBUFFER
|
|
|
|
- "msbuild.exe /property:Configuration=Release;UnsafeByteBuffer=true;OutputPath=tempcsUnsafe /verbosity:minimal FlatBuffers.Test.csproj"
|
|
|
|
- "tempcsUnsafe\\FlatBuffers.Test.exe"
|
2016-12-12 23:43:49 +00:00
|
|
|
# TODO: add more languages.
|
|
|
|
- "cd ..\\.."
|
2016-07-28 00:34:00 +00:00
|
|
|
|
2016-12-12 23:43:49 +00:00
|
|
|
artifacts:
|
2017-08-01 15:34:00 +00:00
|
|
|
- path: $(CONFIGURATION)\flatc.exe
|
2016-12-12 23:43:49 +00:00
|
|
|
name: flatc.exe
|
2017-08-01 15:34:00 +00:00
|
|
|
- path: tests\GeneratedMyGameCode.zip
|
|
|
|
name: GeneratedMyGameCode.zip
|