mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
UnitTestRunner: Fixed some build warnings on Windows
This commit is contained in:
parent
ab13359c66
commit
7fe3e13489
6 changed files with 32 additions and 13 deletions
|
|
@ -30,7 +30,6 @@
|
|||
Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<PlatformToolset>v140</PlatformToolset>
|
||||
<WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
|
|
@ -81,6 +80,7 @@
|
|||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<TreatWarningAsError>true</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
|
@ -122,6 +122,7 @@
|
|||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<TreatWarningAsError>true</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
|
|
|||
|
|
@ -31,7 +31,6 @@
|
|||
Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
<WindowsTargetPlatformVersion>10.0.15063.0</WindowsTargetPlatformVersion>
|
||||
|
|
@ -83,6 +82,7 @@
|
|||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<TreatWarningAsError>true</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
|
@ -122,6 +122,7 @@
|
|||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<TreatWarningAsError>true</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
|
|
|||
|
|
@ -45,16 +45,20 @@ class ConsoleUnitTestRunner : public UnitTestRunner
|
|||
};
|
||||
|
||||
//==============================================================================
|
||||
int main (int argc, char* argv[])
|
||||
int main()
|
||||
{
|
||||
ignoreUnused (argc, argv);
|
||||
|
||||
ScopedPointer<ConsoleLogger> logger;
|
||||
Logger::setCurrentLogger (logger);
|
||||
#if ! JUCE_DEBUG
|
||||
ConsoleLogger logger;
|
||||
Logger::setCurrentLogger (&logger);
|
||||
#endif
|
||||
|
||||
ConsoleUnitTestRunner runner;
|
||||
runner.runAllTests();
|
||||
|
||||
#if ! JUCE_DEBUG
|
||||
Logger::setCurrentLogger (nullptr);
|
||||
#endif
|
||||
|
||||
for (int i = 0; i < runner.getNumResults(); ++i)
|
||||
if (runner.getResult(i)->failures > 0)
|
||||
return 1;
|
||||
|
|
|
|||
|
|
@ -69,9 +69,11 @@
|
|||
<VS2015 targetFolder="Builds/VisualStudio2015">
|
||||
<CONFIGURATIONS>
|
||||
<CONFIGURATION name="Debug" winWarningLevel="4" generateManifest="1" winArchitecture="32-bit"
|
||||
isDebug="1" optimisation="1" targetName="UnitTestRunner"/>
|
||||
isDebug="1" optimisation="1" targetName="UnitTestRunner" warningsAreErrors="1"
|
||||
wholeProgramOptimisation="1"/>
|
||||
<CONFIGURATION name="Release" winWarningLevel="4" generateManifest="1" winArchitecture="32-bit"
|
||||
isDebug="0" optimisation="3" targetName="UnitTestRunner"/>
|
||||
isDebug="0" optimisation="3" targetName="UnitTestRunner" wholeProgramOptimisation="1"
|
||||
warningsAreErrors="1"/>
|
||||
</CONFIGURATIONS>
|
||||
<MODULEPATHS>
|
||||
<MODULEPATH id="juce_video" path="../../modules"/>
|
||||
|
|
@ -96,9 +98,11 @@
|
|||
<VS2017 targetFolder="Builds/VisualStudio2017">
|
||||
<CONFIGURATIONS>
|
||||
<CONFIGURATION name="Debug" winWarningLevel="4" generateManifest="1" winArchitecture="x64"
|
||||
isDebug="1" optimisation="1" targetName="UnitTestRunner"/>
|
||||
isDebug="1" optimisation="1" targetName="UnitTestRunner" warningsAreErrors="1"
|
||||
wholeProgramOptimisation="1"/>
|
||||
<CONFIGURATION name="Release" winWarningLevel="4" generateManifest="1" winArchitecture="x64"
|
||||
isDebug="0" optimisation="3" targetName="UnitTestRunner"/>
|
||||
isDebug="0" optimisation="3" targetName="UnitTestRunner" warningsAreErrors="1"
|
||||
wholeProgramOptimisation="1"/>
|
||||
</CONFIGURATIONS>
|
||||
<MODULEPATHS>
|
||||
<MODULEPATH id="juce_video" path="../../modules"/>
|
||||
|
|
|
|||
|
|
@ -20,6 +20,11 @@
|
|||
==============================================================================
|
||||
*/
|
||||
|
||||
#if JUCE_MSVC
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable: 4702)
|
||||
#endif
|
||||
|
||||
namespace littlefoot
|
||||
{
|
||||
|
||||
|
|
@ -2172,3 +2177,7 @@ private:
|
|||
};
|
||||
|
||||
}
|
||||
|
||||
#if JUCE_MSVC
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1695,7 +1695,7 @@ struct PhysicalTopologySource::Internal
|
|||
}
|
||||
}
|
||||
|
||||
bool setName (const juce::String& name) override
|
||||
bool setName (const juce::String& newName) override
|
||||
{
|
||||
auto index = getDeviceIndex();
|
||||
|
||||
|
|
@ -1704,7 +1704,7 @@ struct PhysicalTopologySource::Internal
|
|||
BlocksProtocol::HostPacketBuilder<128> p;
|
||||
p.writePacketSysexHeaderBytes ((BlocksProtocol::TopologyIndex) index);
|
||||
|
||||
if (p.addSetBlockName (name))
|
||||
if (p.addSetBlockName (newName))
|
||||
{
|
||||
p.writePacketSysexFooter();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue