Skip to content

Commit 76b0186

Browse files
fixes opencv version check + attempt to fix appveyor.yml
1 parent 74ec512 commit 76b0186

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

appveyor.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,12 +50,10 @@ environment:
5050

5151
install:
5252
- cmd: choco install OpenCV -y -version %OPENCV_VERSION%
53-
- if not "%BUILD_TASK%" == "ENVS" (
54-
SET OPENCV_INCLUDE_DIR="c:\tools\opencv\build\include" &&
55-
SET OPENCV_LIB_DIR="c:\tools\opencv\build\x64\vc14\lib" &&
56-
SET OPENCV_BIN_DIR="c:\tools\opencv\build\x64\vc14\bin" &&
57-
SET PATH="%PATH%;%OPENCV_BIN_DIR%;"
58-
)
53+
- if not "%BUILD_TASK%" == "ENVS" SET OPENCV_INCLUDE_DIR=c:\tools\opencv\build\include
54+
- if not "%BUILD_TASK%" == "ENVS" SET OPENCV_LIB_DIR=c:\tools\opencv\build\x64\vc14\lib
55+
- if not "%BUILD_TASK%" == "ENVS" SET OPENCV_BIN_DIR=c:\tools\opencv\build\x64\vc14\bin
56+
- if not "%BUILD_TASK%" == "ENVS" SET PATH=%PATH%;%OPENCV_BIN_DIR%;
5957
- ps: Install-Product node $env:nodejs_version x64
6058
- node --version
6159
- npm install -g node-gyp

test/tests/index.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ describe('cv', () => {
7676
console.log('expected modules to be built:', builtModules)
7777

7878
it('OpenCV version should match', () => {
79-
expect(process.env.OPENCV_VERSION).to.equal(opencvVersionString)
79+
expect((process.env.OPENCV_VERSION || '').substr(0, 5)).to.equal(opencvVersionString)
8080
})
8181

8282
it('all modules should be built', () => {

0 commit comments

Comments
 (0)