mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-02-02 10:00:38 +01:00
Add test framework in common library.
This commit is contained in:
parent
6a8de73762
commit
bb5a1e0149
7
.github/workflows/main.yml
vendored
7
.github/workflows/main.yml
vendored
@ -58,6 +58,8 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
CC=clang CXX=clang++ ./autogen.sh --enable-binreloc --prefix=/opt/firebird
|
CC=clang CXX=clang++ ./autogen.sh --enable-binreloc --prefix=/opt/firebird
|
||||||
make -j4
|
make -j4
|
||||||
|
make tests -j4
|
||||||
|
make run_tests
|
||||||
make dist
|
make dist
|
||||||
tar xzvf gen/Firebird-[0-9]*.tar.gz
|
tar xzvf gen/Firebird-[0-9]*.tar.gz
|
||||||
(cd Firebird-[0-9]*; sudo ./install.sh -silent)
|
(cd Firebird-[0-9]*; sudo ./install.sh -silent)
|
||||||
@ -82,6 +84,8 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
./autogen.sh --enable-binreloc-threads --with-builtin-tommath --with-builtin-tomcrypt --prefix=/opt/firebird
|
./autogen.sh --enable-binreloc-threads --with-builtin-tommath --with-builtin-tomcrypt --prefix=/opt/firebird
|
||||||
make -j4
|
make -j4
|
||||||
|
make tests -j4
|
||||||
|
make run_tests
|
||||||
make dist
|
make dist
|
||||||
tar xzvf gen/Firebird-[0-9]*.tar.gz
|
tar xzvf gen/Firebird-[0-9]*.tar.gz
|
||||||
|
|
||||||
@ -128,6 +132,8 @@ jobs:
|
|||||||
|
|
||||||
LIBRARY_PATH="$ICU_INSTALL_PATH/lib:$LIBRARY_PATH" ./autogen.sh --with-builtin-tommath --with-builtin-tomcrypt
|
LIBRARY_PATH="$ICU_INSTALL_PATH/lib:$LIBRARY_PATH" ./autogen.sh --with-builtin-tommath --with-builtin-tomcrypt
|
||||||
make -j4
|
make -j4
|
||||||
|
make tests -j4
|
||||||
|
make run_tests
|
||||||
|
|
||||||
(cd gen; make -B -f make.platform.postfix ICU_LOC="$ICU_INSTALL_PATH/lib/")
|
(cd gen; make -B -f make.platform.postfix ICU_LOC="$ICU_INSTALL_PATH/lib/")
|
||||||
(cd gen; make -B -f Makefile.install)
|
(cd gen; make -B -f Makefile.install)
|
||||||
@ -167,6 +173,7 @@ jobs:
|
|||||||
call "%VS_SCRIPT%" -arch=%FB_VS_ARCH%
|
call "%VS_SCRIPT%" -arch=%FB_VS_ARCH%
|
||||||
cd builds\win32
|
cd builds\win32
|
||||||
run_all.bat JUSTBUILD
|
run_all.bat JUSTBUILD
|
||||||
|
run_tests.bat
|
||||||
|
|
||||||
- name: Build (Windows, Docker)
|
- name: Build (Windows, Docker)
|
||||||
if: startsWith(matrix.os, 'windows-') && matrix.docker
|
if: startsWith(matrix.os, 'windows-') && matrix.docker
|
||||||
|
@ -11,4 +11,6 @@ cd /d C:\firebird-build\builds\win32
|
|||||||
REM call run_all.bat
|
REM call run_all.bat
|
||||||
call run_all.bat JUSTBUILD
|
call run_all.bat JUSTBUILD
|
||||||
|
|
||||||
|
call run_tests.bat
|
||||||
|
|
||||||
xcopy /h /e /i /q C:\firebird-build\output_%FB_OUTPUT_SUFFIX%\* C:\firebird-out
|
xcopy /h /e /i /q C:\firebird-build\output_%FB_OUTPUT_SUFFIX%\* C:\firebird-out
|
||||||
|
@ -11,4 +11,6 @@ cd /d C:\firebird-build\builds\win32
|
|||||||
REM call run_all.bat
|
REM call run_all.bat
|
||||||
call run_all.bat JUSTBUILD
|
call run_all.bat JUSTBUILD
|
||||||
|
|
||||||
|
call run_tests.bat
|
||||||
|
|
||||||
xcopy /h /e /i /q C:\firebird-build\output_%FB_OUTPUT_SUFFIX%\* C:\firebird-out
|
xcopy /h /e /i /q C:\firebird-build\output_%FB_OUTPUT_SUFFIX%\* C:\firebird-out
|
||||||
|
@ -361,6 +361,8 @@ $(COMMON_LIB): $(Common_Objects)
|
|||||||
-$(RM) $@
|
-$(RM) $@
|
||||||
$(STATICLIB_LINK) $@ $^
|
$(STATICLIB_LINK) $@ $^
|
||||||
|
|
||||||
|
$(COMMON_TEST): $(Common_Test_Objects) $(COMMON_LIB)
|
||||||
|
$(EXE_LINK) $(EXE_LINK_OPTIONS) $^ -o $@ -L$(LIB) $(LINK_LIBS)
|
||||||
|
|
||||||
#___________________________________________________________________________
|
#___________________________________________________________________________
|
||||||
# gpre_boot
|
# gpre_boot
|
||||||
@ -711,6 +713,24 @@ install install-embedded silent_install package packages dist:
|
|||||||
$(MAKE) -f Makefile.install $@
|
$(MAKE) -f Makefile.install $@
|
||||||
|
|
||||||
|
|
||||||
|
#___________________________________________________________________________
|
||||||
|
# tests
|
||||||
|
#
|
||||||
|
|
||||||
|
.PHONY: tests tests_process run_tests run_tests_process
|
||||||
|
|
||||||
|
tests:
|
||||||
|
$(MAKE) TARGET=$(DefaultTarget) tests_process
|
||||||
|
|
||||||
|
tests_process: $(COMMON_TEST)
|
||||||
|
|
||||||
|
run_tests:
|
||||||
|
$(MAKE) TARGET=$(DefaultTarget) run_tests_process
|
||||||
|
|
||||||
|
run_tests_process: tests_process
|
||||||
|
$(COMMON_TEST) --log_level=all
|
||||||
|
|
||||||
|
|
||||||
#___________________________________________________________________________
|
#___________________________________________________________________________
|
||||||
# various cleaning
|
# various cleaning
|
||||||
#
|
#
|
||||||
|
@ -53,6 +53,8 @@ RE2_BUILD_FLG=@RE2_BUILD@
|
|||||||
SYSTEM_BOOST_FLG=@SYSTEM_BOOST@
|
SYSTEM_BOOST_FLG=@SYSTEM_BOOST@
|
||||||
|
|
||||||
FB_BUILD=$(GEN_ROOT)/$(TARGET)/firebird
|
FB_BUILD=$(GEN_ROOT)/$(TARGET)/firebird
|
||||||
|
FB_TEST_BUILD=$(GEN_ROOT)/$(TARGET)/tests
|
||||||
|
|
||||||
ifeq ($(IsCross), Y)
|
ifeq ($(IsCross), Y)
|
||||||
FIREBIRD=$(GEN_ROOT)/Native/firebird
|
FIREBIRD=$(GEN_ROOT)/Native/firebird
|
||||||
else
|
else
|
||||||
@ -386,6 +388,7 @@ LINK_PLUG_LIBS = -L$(LIB) $(SO_LINK_LIBS)
|
|||||||
# Pay attention - we place common library into obj, not lib dir
|
# Pay attention - we place common library into obj, not lib dir
|
||||||
# It's just a set of object files, prepared to be used by ld, not an output library
|
# It's just a set of object files, prepared to be used by ld, not an output library
|
||||||
COMMON_LIB = $(OBJ)/common.a
|
COMMON_LIB = $(OBJ)/common.a
|
||||||
|
COMMON_TEST = $(FB_TEST_BUILD)/common_test$(EXEC_EXT)
|
||||||
|
|
||||||
# From utilities
|
# From utilities
|
||||||
CREATE_DB = $(RBIN)/create_db$(EXEC_EXT)
|
CREATE_DB = $(RBIN)/create_db$(EXEC_EXT)
|
||||||
|
@ -34,6 +34,10 @@
|
|||||||
# Please don't use compiler/platform specific flags here - nmcc 02-Nov-2002
|
# Please don't use compiler/platform specific flags here - nmcc 02-Nov-2002
|
||||||
WFLAGS =-I$(SRC_ROOT)/include/gen -I$(SRC_ROOT)/include $(CPPFLAGS) $(LTCSOURCE)
|
WFLAGS =-I$(SRC_ROOT)/include/gen -I$(SRC_ROOT)/include $(CPPFLAGS) $(LTCSOURCE)
|
||||||
|
|
||||||
|
ifneq ($(SYSTEM_BOOST_FLG),Y)
|
||||||
|
WFLAGS += -I$(ROOT)/extern/boost
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(TOMMATH_BUILD_FLG),Y)
|
ifeq ($(TOMMATH_BUILD_FLG),Y)
|
||||||
WFLAGS += -I$(TOMMATH_INC)
|
WFLAGS += -I$(TOMMATH_INC)
|
||||||
endif
|
endif
|
||||||
|
@ -36,12 +36,18 @@ Common_Objects:= $(CO1) $(CO2) $(CO3) $(CO4)
|
|||||||
|
|
||||||
AllObjects += $(Common_Objects)
|
AllObjects += $(Common_Objects)
|
||||||
|
|
||||||
|
# Common test files
|
||||||
|
COT1:= $(call dirObjects,common/tests)
|
||||||
|
Common_Test_Objects:= $(COT1)
|
||||||
|
|
||||||
|
AllObjects += $(Common_Test_Objects)
|
||||||
|
|
||||||
|
|
||||||
# gpre
|
# gpre
|
||||||
GPRE_Common_Objects:= $(call dirObjects,gpre) $(call makeObjects,gpre/languages,@GPRE_LANGUAGE_MODULES@)
|
GPRE_Common_Objects:= $(call dirObjects,gpre) $(call makeObjects,gpre/languages,@GPRE_LANGUAGE_MODULES@)
|
||||||
GPRE_std:= $(call dirObjects,gpre/std)
|
GPRE_std:= $(call dirObjects,gpre/std)
|
||||||
GPRE_Objects:= $(GPRE_Common_Objects) $(GPRE_std)
|
GPRE_Objects:= $(GPRE_Common_Objects) $(GPRE_std)
|
||||||
GPRE_boot:= $(call dirObjects,gpre/boot) $(call makeObjects,yvalve,gds.cpp)
|
GPRE_boot:= $(call dirObjects,gpre/boot)
|
||||||
GPRE_Boot_Objects:= $(GPRE_Common_Objects) $(GPRE_boot)
|
GPRE_Boot_Objects:= $(GPRE_Common_Objects) $(GPRE_boot)
|
||||||
|
|
||||||
AllObjects += $(GPRE_Common_Objects) $(GPRE_std) $(GPRE_boot)
|
AllObjects += $(GPRE_Common_Objects) $(GPRE_std) $(GPRE_boot)
|
||||||
|
24
builds/win32/make_tests.bat
Normal file
24
builds/win32/make_tests.bat
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
@echo off
|
||||||
|
set ERRLEV=0
|
||||||
|
|
||||||
|
:: Set env vars
|
||||||
|
@call setenvvar.bat
|
||||||
|
|
||||||
|
@if errorlevel 1 (call :ERROR Executing setenvvar.bat failed & goto :EOF)
|
||||||
|
|
||||||
|
:: verify that boot was run before
|
||||||
|
|
||||||
|
@if not exist %FB_GEN_DIR%\firebird.msg (goto :HELP_BOOT & goto :EOF)
|
||||||
|
|
||||||
|
|
||||||
|
@call set_build_target.bat %*
|
||||||
|
|
||||||
|
::==========
|
||||||
|
:: MAIN
|
||||||
|
|
||||||
|
@echo Building %FB_OBJ_DIR%
|
||||||
|
|
||||||
|
call compile.bat builds\win32\%VS_VER%\FirebirdTests make_tests_%FB_TARGET_PLATFORM%.log
|
||||||
|
if errorlevel 1 call :ERROR build failed - see make_tests_%FB_TARGET_PLATFORM%.log for details
|
||||||
|
|
||||||
|
@goto :EOF
|
@ -10,7 +10,7 @@
|
|||||||
<ClCompile>
|
<ClCompile>
|
||||||
<AdditionalOptions>/EHsc- %(AdditionalOptions)</AdditionalOptions>
|
<AdditionalOptions>/EHsc- %(AdditionalOptions)</AdditionalOptions>
|
||||||
<OmitFramePointers>true</OmitFramePointers>
|
<OmitFramePointers>true</OmitFramePointers>
|
||||||
<AdditionalIncludeDirectories>../../../src/include;../../../src/include/gen;../../../extern/libtomcrypt/src/headers;../../../extern/libtommath;../../../extern/icu/include;../../../extern/zlib;../../../extern/re2;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>../../../src/include;../../../src/include/gen;../../../extern/libtomcrypt/src/headers;../../../extern/libtommath;../../../extern/icu/include;../../../extern/zlib;../../../extern/re2;../../../extern/boost;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||||
<ExceptionHandling>
|
<ExceptionHandling>
|
||||||
</ExceptionHandling>
|
</ExceptionHandling>
|
||||||
<RuntimeTypeInfo>false</RuntimeTypeInfo>
|
<RuntimeTypeInfo>false</RuntimeTypeInfo>
|
||||||
|
40
builds/win32/msvc15/FirebirdTests.sln
Normal file
40
builds/win32/msvc15/FirebirdTests.sln
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
|
# Visual Studio 15
|
||||||
|
VisualStudioVersion = 15.0.27703.2047
|
||||||
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common", "common.vcxproj", "{15605F44-BFFD-444F-AD4C-55DC9D704465}"
|
||||||
|
EndProject
|
||||||
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common_test", "common_test.vcxproj", "{035D26F9-B406-4D60-A8B7-172098479254}"
|
||||||
|
EndProject
|
||||||
|
Global
|
||||||
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
|
Debug|Win32 = Debug|Win32
|
||||||
|
Debug|x64 = Debug|x64
|
||||||
|
Release|Win32 = Release|Win32
|
||||||
|
Release|x64 = Release|x64
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Debug|Win32.Build.0 = Debug|Win32
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Release|Win32.ActiveCfg = Release|Win32
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Release|Win32.Build.0 = Release|Win32
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Release|x64.ActiveCfg = Release|x64
|
||||||
|
{15605F44-BFFD-444F-AD4C-55DC9D704465}.Release|x64.Build.0 = Release|x64
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Debug|Win32.Build.0 = Debug|Win32
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Debug|x64.Build.0 = Debug|x64
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Release|Win32.ActiveCfg = Release|Win32
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Release|Win32.Build.0 = Release|Win32
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Release|x64.ActiveCfg = Release|x64
|
||||||
|
{035D26F9-B406-4D60-A8B7-172098479254}.Release|x64.Build.0 = Release|x64
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
|
HideSolutionNode = FALSE
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||||
|
SolutionGuid = {97076DB2-CFCD-4277-BDF0-A6407852E1AC}
|
||||||
|
EndGlobalSection
|
||||||
|
EndGlobal
|
205
builds/win32/msvc15/common_test.vcxproj
Normal file
205
builds/win32/msvc15/common_test.vcxproj
Normal file
@ -0,0 +1,205 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<ItemGroup Label="ProjectConfigurations">
|
||||||
|
<ProjectConfiguration Include="Debug|Win32">
|
||||||
|
<Configuration>Debug</Configuration>
|
||||||
|
<Platform>Win32</Platform>
|
||||||
|
</ProjectConfiguration>
|
||||||
|
<ProjectConfiguration Include="Debug|x64">
|
||||||
|
<Configuration>Debug</Configuration>
|
||||||
|
<Platform>x64</Platform>
|
||||||
|
</ProjectConfiguration>
|
||||||
|
<ProjectConfiguration Include="Release|Win32">
|
||||||
|
<Configuration>Release</Configuration>
|
||||||
|
<Platform>Win32</Platform>
|
||||||
|
</ProjectConfiguration>
|
||||||
|
<ProjectConfiguration Include="Release|x64">
|
||||||
|
<Configuration>Release</Configuration>
|
||||||
|
<Platform>x64</Platform>
|
||||||
|
</ProjectConfiguration>
|
||||||
|
</ItemGroup>
|
||||||
|
<PropertyGroup Label="Globals">
|
||||||
|
<ProjectGuid>{035D26F9-B406-4D60-A8B7-172098479254}</ProjectGuid>
|
||||||
|
<RootNamespace>common_test</RootNamespace>
|
||||||
|
<WindowsTargetPlatformVersion Condition="'$(VisualStudioVersion)'=='15.0'">10.0.17763.0</WindowsTargetPlatformVersion>
|
||||||
|
<WindowsTargetPlatformVersion Condition="'$(VisualStudioVersion)'=='16.0'">10.0</WindowsTargetPlatformVersion>
|
||||||
|
<WindowsTargetPlatformVersion Condition="'$(VisualStudioVersion)'=='17.0'">10.0</WindowsTargetPlatformVersion>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||||
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
|
<UseOfMfc>false</UseOfMfc>
|
||||||
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='15.0'">v141_xp</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='16.0'">v142</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='17.0'">v143</PlatformToolset>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||||
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
|
<UseOfMfc>false</UseOfMfc>
|
||||||
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='15.0'">v141_xp</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='16.0'">v142</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='17.0'">v143</PlatformToolset>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||||
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
|
<UseOfMfc>false</UseOfMfc>
|
||||||
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='15.0'">v141</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='16.0'">v142</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='17.0'">v143</PlatformToolset>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||||
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
|
<UseOfMfc>false</UseOfMfc>
|
||||||
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='15.0'">v141</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='16.0'">v142</PlatformToolset>
|
||||||
|
<PlatformToolset Condition="'$(VisualStudioVersion)'=='17.0'">v143</PlatformToolset>
|
||||||
|
</PropertyGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||||
|
<ImportGroup Label="ExtensionSettings">
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" />
|
||||||
|
<Import Project="FirebirdCommon.props" />
|
||||||
|
<Import Project="FirebirdDebug.props" />
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" />
|
||||||
|
<Import Project="FirebirdCommon.props" />
|
||||||
|
<Import Project="FirebirdRelease.props" />
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" />
|
||||||
|
<Import Project="FirebirdCommon.props" />
|
||||||
|
<Import Project="FirebirdDebug.props" />
|
||||||
|
</ImportGroup>
|
||||||
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||||
|
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||||
|
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC71.props" />
|
||||||
|
<Import Project="FirebirdCommon.props" />
|
||||||
|
<Import Project="FirebirdRelease.props" />
|
||||||
|
</ImportGroup>
|
||||||
|
<PropertyGroup Label="UserMacros" />
|
||||||
|
<PropertyGroup>
|
||||||
|
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
|
||||||
|
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
|
||||||
|
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">false</LinkIncremental>
|
||||||
|
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</LinkIncremental>
|
||||||
|
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</LinkIncremental>
|
||||||
|
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
|
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
|
||||||
|
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
|
||||||
|
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
|
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" />
|
||||||
|
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" />
|
||||||
|
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
|
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
|
||||||
|
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
|
||||||
|
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|x64'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||||
|
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|x64'" />
|
||||||
|
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|x64'" />
|
||||||
|
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\..\temp\$(PlatformName)\$(Configuration)\tests\</OutDir>
|
||||||
|
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\..\temp\$(PlatformName)\$(Configuration)\tests\</OutDir>
|
||||||
|
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">..\..\..\temp\$(PlatformName)\$(Configuration)\tests\</OutDir>
|
||||||
|
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|x64'">..\..\..\temp\$(PlatformName)\$(Configuration)\tests\</OutDir>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||||
|
<ClCompile>
|
||||||
|
<Optimization>MaxSpeed</Optimization>
|
||||||
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
|
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||||
|
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||||
|
<PreprocessorDefinitions>NDEBUG;_CONSOLE;SUPERCLIENT;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
<BrowseInformation>true</BrowseInformation>
|
||||||
|
</ClCompile>
|
||||||
|
<Link>
|
||||||
|
<AdditionalDependencies>comctl32.lib;ws2_32.lib;mpr.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
|
<SubSystem>Console</SubSystem>
|
||||||
|
<RandomizedBaseAddress>false</RandomizedBaseAddress>
|
||||||
|
<DataExecutionPrevention>
|
||||||
|
</DataExecutionPrevention>
|
||||||
|
</Link>
|
||||||
|
</ItemDefinitionGroup>
|
||||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||||
|
<ClCompile>
|
||||||
|
<Optimization>Disabled</Optimization>
|
||||||
|
<PreprocessorDefinitions>_DEBUG;_CONSOLE;SUPERCLIENT;WIN32;DEV_BUILD;_WINDOWS;_USRDLL;CLIENT;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
<BrowseInformation>true</BrowseInformation>
|
||||||
|
</ClCompile>
|
||||||
|
<Link>
|
||||||
|
<AdditionalDependencies>comctl32.lib;ws2_32.lib;mpr.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
|
<SubSystem>Console</SubSystem>
|
||||||
|
<RandomizedBaseAddress>false</RandomizedBaseAddress>
|
||||||
|
<DataExecutionPrevention>
|
||||||
|
</DataExecutionPrevention>
|
||||||
|
</Link>
|
||||||
|
</ItemDefinitionGroup>
|
||||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||||
|
<Midl>
|
||||||
|
<TargetEnvironment>X64</TargetEnvironment>
|
||||||
|
</Midl>
|
||||||
|
<ClCompile>
|
||||||
|
<Optimization>MaxSpeed</Optimization>
|
||||||
|
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||||
|
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||||
|
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||||
|
<PreprocessorDefinitions>NDEBUG;_CONSOLE;SUPERCLIENT;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
</ClCompile>
|
||||||
|
<Link>
|
||||||
|
<AdditionalDependencies>comctl32.lib;ws2_32.lib;mpr.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
|
<SubSystem>Console</SubSystem>
|
||||||
|
<RandomizedBaseAddress>false</RandomizedBaseAddress>
|
||||||
|
<DataExecutionPrevention>
|
||||||
|
</DataExecutionPrevention>
|
||||||
|
<TargetMachine>MachineX64</TargetMachine>
|
||||||
|
</Link>
|
||||||
|
</ItemDefinitionGroup>
|
||||||
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||||
|
<Midl>
|
||||||
|
<TargetEnvironment>X64</TargetEnvironment>
|
||||||
|
</Midl>
|
||||||
|
<ClCompile>
|
||||||
|
<Optimization>Disabled</Optimization>
|
||||||
|
<PreprocessorDefinitions>_DEBUG;_CONSOLE;SUPERCLIENT;WIN32;DEV_BUILD;_WINDOWS;_USRDLL;CLIENT;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
|
<BrowseInformation>true</BrowseInformation>
|
||||||
|
</ClCompile>
|
||||||
|
<Link>
|
||||||
|
<AdditionalDependencies>comctl32.lib;ws2_32.lib;mpr.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||||
|
<SubSystem>Console</SubSystem>
|
||||||
|
<RandomizedBaseAddress>false</RandomizedBaseAddress>
|
||||||
|
<DataExecutionPrevention>
|
||||||
|
</DataExecutionPrevention>
|
||||||
|
<TargetMachine>MachineX64</TargetMachine>
|
||||||
|
</Link>
|
||||||
|
</ItemDefinitionGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ResourceCompile Include="..\..\..\src\jrd\version.rc">
|
||||||
|
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\..\src\jrd</AdditionalIncludeDirectories>
|
||||||
|
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">..\..\..\src\jrd</AdditionalIncludeDirectories>
|
||||||
|
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\..\src\jrd</AdditionalIncludeDirectories>
|
||||||
|
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|x64'">..\..\..\src\jrd</AdditionalIncludeDirectories>
|
||||||
|
</ResourceCompile>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ClCompile Include="..\..\..\src\common\tests\CommonTest.cpp" />
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="common.vcxproj">
|
||||||
|
<Project>{15605f44-bffd-444f-ad4c-55dc9d704465}</Project>
|
||||||
|
<Private>true</Private>
|
||||||
|
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
|
||||||
|
<CopyLocalSatelliteAssemblies>false</CopyLocalSatelliteAssemblies>
|
||||||
|
<LinkLibraryDependencies>true</LinkLibraryDependencies>
|
||||||
|
<UseLibraryDependencyInputs>false</UseLibraryDependencyInputs>
|
||||||
|
</ProjectReference>
|
||||||
|
</ItemGroup>
|
||||||
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
|
<ImportGroup Label="ExtensionTargets">
|
||||||
|
</ImportGroup>
|
||||||
|
</Project>
|
22
builds/win32/msvc15/common_test.vcxproj.filters
Normal file
22
builds/win32/msvc15/common_test.vcxproj.filters
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<ItemGroup>
|
||||||
|
<Filter Include="Resource files">
|
||||||
|
<UniqueIdentifier>{59426d65-9f63-49b9-b8c1-9416f4875c62}</UniqueIdentifier>
|
||||||
|
</Filter>
|
||||||
|
<Filter Include="source">
|
||||||
|
<UniqueIdentifier>{487dc529-1110-47e9-a3aa-907ca1b16858}</UniqueIdentifier>
|
||||||
|
<Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions>
|
||||||
|
</Filter>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ResourceCompile Include="..\..\..\src\jrd\version.rc">
|
||||||
|
<Filter>Resource files</Filter>
|
||||||
|
</ResourceCompile>
|
||||||
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<ClCompile Include="..\..\..\src\common\tests\CommonTest.cpp">
|
||||||
|
<Filter>source</Filter>
|
||||||
|
</ClCompile>
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
@ -47,6 +47,8 @@ call make_boot %FBBUILD_BUILDTYPE%
|
|||||||
if "%ERRLEV%"=="1" goto :END
|
if "%ERRLEV%"=="1" goto :END
|
||||||
call make_all %FBBUILD_BUILDTYPE%
|
call make_all %FBBUILD_BUILDTYPE%
|
||||||
if "%ERRLEV%"=="1" goto :END
|
if "%ERRLEV%"=="1" goto :END
|
||||||
|
call make_tests %FBBUILD_BUILDTYPE%
|
||||||
|
if "%ERRLEV%"=="1" goto :END
|
||||||
call make_examples %FBBUILD_BUILDTYPE%
|
call make_examples %FBBUILD_BUILDTYPE%
|
||||||
if "%ERRLEV%"=="1" goto :END
|
if "%ERRLEV%"=="1" goto :END
|
||||||
|
|
||||||
|
12
builds/win32/run_tests.bat
Normal file
12
builds/win32/run_tests.bat
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
@echo.
|
||||||
|
|
||||||
|
@call setenvvar.bat
|
||||||
|
@if errorlevel 1 (goto :END)
|
||||||
|
|
||||||
|
@call set_build_target.bat %*
|
||||||
|
|
||||||
|
@%FB_TESTS_DIR%\common_test --log_level=all
|
||||||
|
|
||||||
|
:END
|
@ -13,6 +13,7 @@ for %%v in ( %* ) do (
|
|||||||
|
|
||||||
set FB_OBJ_DIR=%FB_TARGET_PLATFORM%\%FB_CONFIG%
|
set FB_OBJ_DIR=%FB_TARGET_PLATFORM%\%FB_CONFIG%
|
||||||
set FB_BIN_DIR=%FB_ROOT_PATH%\temp\%FB_OBJ_DIR%\firebird\
|
set FB_BIN_DIR=%FB_ROOT_PATH%\temp\%FB_OBJ_DIR%\firebird\
|
||||||
|
set FB_TESTS_DIR=%FB_ROOT_PATH%\temp\%FB_OBJ_DIR%\tests\
|
||||||
|
|
||||||
@echo Executed %0
|
@echo Executed %0
|
||||||
@echo.
|
@echo.
|
||||||
|
@ -574,6 +574,7 @@ AC_ARG_WITH(system-re2,
|
|||||||
[RE2_BUILD=N])
|
[RE2_BUILD=N])
|
||||||
AC_SUBST(RE2_BUILD)
|
AC_SUBST(RE2_BUILD)
|
||||||
|
|
||||||
|
dnl This is currently used for internal and public (API headers) needs
|
||||||
SYSTEM_BOOST=N
|
SYSTEM_BOOST=N
|
||||||
AC_ARG_WITH(system-boost,
|
AC_ARG_WITH(system-boost,
|
||||||
[ --with-system-boost use system-wide boost library instead of embedded copy],
|
[ --with-system-boost use system-wide boost library instead of embedded copy],
|
||||||
@ -1310,6 +1311,7 @@ dnl # output
|
|||||||
mkdir -p gen/\$fb_tgt/firebird/include/firebird/impl
|
mkdir -p gen/\$fb_tgt/firebird/include/firebird/impl
|
||||||
mkdir -p gen/\$fb_tgt/firebird/lib
|
mkdir -p gen/\$fb_tgt/firebird/lib
|
||||||
mkdir -p gen/\$fb_tgt/firebird/misc
|
mkdir -p gen/\$fb_tgt/firebird/misc
|
||||||
|
mkdir -p gen/\$fb_tgt/tests
|
||||||
|
|
||||||
dnl ### TEMP ### directories for generated .cpp, .o and .d by module name
|
dnl ### TEMP ### directories for generated .cpp, .o and .d by module name
|
||||||
for src_dir in `cd src; ls -R -1 * | grep : | tr -d : | tr "\n" " "; cd ..`; do
|
for src_dir in `cd src; ls -R -1 * | grep : | tr -d : | tr "\n" " "; cd ..`; do
|
||||||
|
22
src/common/tests/CommonTest.cpp
Normal file
22
src/common/tests/CommonTest.cpp
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#include "firebird.h"
|
||||||
|
#include "firebird/Interface.h"
|
||||||
|
#include "../common/gdsassert.h"
|
||||||
|
|
||||||
|
#define BOOST_TEST_MODULE CommonTest
|
||||||
|
#include "boost/test/included/unit_test.hpp"
|
||||||
|
|
||||||
|
|
||||||
|
int ISC_EXPORT fb_shutdown(unsigned int, const int)
|
||||||
|
{
|
||||||
|
fb_assert(false);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
namespace Firebird
|
||||||
|
{
|
||||||
|
IMaster* API_ROUTINE fb_get_master_interface()
|
||||||
|
{
|
||||||
|
fb_assert(false);
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user