From 91cab26a5c801b9573dde5217a21e8e8ca3d3eb1 Mon Sep 17 00:00:00 2001 From: alikh31 Date: Thu, 8 May 2014 18:31:40 +0200 Subject: [PATCH] fix up #8 --- src/StringUtility.h | 2 +- vcbuild.bat | 19 +++++++++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/src/StringUtility.h b/src/StringUtility.h index 64520b60..a1eaa828 100644 --- a/src/StringUtility.h +++ b/src/StringUtility.h @@ -22,7 +22,7 @@ namespace snowcrash { // Check a character not to be an space of any kind - inline bool isSpace(const char i){ + inline bool isSpace(const std::string::value_type i){ if(i == ' ' || i == '\t' || i == '\n' || i == '\v' || i == '\f' || i == '\r') return true; return false; diff --git a/vcbuild.bat b/vcbuild.bat index 29ba41a5..a0d4e5c5 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -105,9 +105,24 @@ goto exit :run-integration-test if "%config%"=="Debug" ( -echo Warning: Integration Tests has been configured to use 'Release' executables, please use 'vcbuild.bat' without 'debug' option. -goto exit +SET "Replacement= ENV['PATH'] = "../../build/Debug"" +goto :run-cucumber ) +SET "Replacement= ENV['PATH'] = "../../build/Release"" +goto :run-cucumber + +:run-cucumber +SET "file=features\support\env.rb" +SET /a Line#ToSearch=9 +(FOR /f "tokens=1*delims=:" %%a IN ('findstr /n "^" "%file%"') DO ( + SET "Line=%%b" + IF %%a equ %Line#ToSearch% SET "Line=%Replacement%" + SETLOCAL ENABLEDELAYEDEXPANSION + ECHO(!Line!) + ENDLOCAL +)>"%file%.new" +MOVE "%file%.new" "%file%" >nul + bundle exec cucumber goto exit