Fix Appveyor tests
Formatting
This commit is contained in:
parent
b49acb3aa8
commit
710d078824
@ -88,7 +88,9 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
set(PEDANTIC_COMPILE_FLAGS -Weverything -Wpedantic
|
||||
-Wno-weak-vtables -Wno-padded -Wno-gnu-statement-expression
|
||||
-Wno-c++98-compat -Wno-c++98-compat-pedantic -Wno-reserved-id-macro
|
||||
-Wno-global-constructors -Wno-disabled-macro-expansion)
|
||||
-Wno-global-constructors -Wno-disabled-macro-expansion
|
||||
-Wno-switch-enum -Wno-documentation-unknown-command
|
||||
-Wno-gnu-string-literal-operator-template)
|
||||
|
||||
set(WERROR_FLAG -Werror)
|
||||
endif ()
|
||||
|
||||
@ -558,8 +558,8 @@ template <typename Context, typename T>
|
||||
FMT_CONSTEXPR basic_format_arg<Context> make_arg(const T &value);
|
||||
|
||||
#if FMT_GCC_VERSION >= 406
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wuseless-cast"
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wuseless-cast"
|
||||
#endif
|
||||
|
||||
#define FMT_MAKE_VALUE(TAG, ArgType, ValueType) \
|
||||
@ -631,7 +631,7 @@ FMT_MAKE_VALUE(pointer_type, std::nullptr_t, const void*)
|
||||
|
||||
#if FMT_GCC_VERSION >= 406
|
||||
// -Wuseless-cast
|
||||
#pragma GCC diagnostic pop
|
||||
# pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
// Formatting of arbitrary pointers is disallowed. If you want to output a
|
||||
|
||||
@ -115,8 +115,8 @@ int safe_strerror(
|
||||
void operator=(const StrError &) {}
|
||||
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wunused-member-function"
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wunused-member-function"
|
||||
#endif
|
||||
|
||||
// Handle the result of XSI-compliant version of strerror_r.
|
||||
@ -154,7 +154,7 @@ int safe_strerror(
|
||||
}
|
||||
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic pop
|
||||
# pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
public:
|
||||
@ -223,8 +223,8 @@ FMT_FUNC void system_error::init(
|
||||
|
||||
namespace internal {
|
||||
#if FMT_GCC_VERSION >= 406 || FMT_CLANG_VERSION
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wformat-nonliteral"
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wformat-nonliteral"
|
||||
#endif
|
||||
|
||||
template <typename T>
|
||||
@ -256,7 +256,7 @@ int char_traits<wchar_t>::format_float(
|
||||
}
|
||||
|
||||
#if FMT_GCC_VERSION >= 406 || FMT_CLANG_VERSION
|
||||
#pragma GCC diagnostic pop
|
||||
# pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
template <typename T>
|
||||
@ -479,14 +479,14 @@ void basic_fixed_buffer<Char>::grow(std::size_t) {
|
||||
}
|
||||
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wmissing-noreturn"
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wmissing-noreturn"
|
||||
#endif
|
||||
FMT_FUNC void internal::error_handler::on_error(const char *message) {
|
||||
FMT_THROW(format_error(message));
|
||||
}
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic pop
|
||||
# pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
FMT_FUNC void report_system_error(
|
||||
|
||||
@ -77,9 +77,16 @@
|
||||
|
||||
#if FMT_CLANG_VERSION && !FMT_ICC_VERSION
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wswitch-enum"
|
||||
# pragma clang diagnostic ignored "-Wweak-vtables"
|
||||
# pragma clang diagnostic ignored "-Wpadded"
|
||||
# pragma clang diagnostic ignored "-Wgnu-statement-expression"
|
||||
# pragma clang diagnostic ignored "-Wc++98-compat"
|
||||
# pragma clang diagnostic ignored "-Wc++98-compat-pedantic"
|
||||
# pragma clang diagnostic ignored "-Wglobal-constructors"
|
||||
# pragma clang diagnostic ignored "-Wdisabled-macro-expansion"
|
||||
# pragma clang diagnostic ignored "-Wdocumentation-unknown-command"
|
||||
# pragma clang diagnostic ignored "-Wgnu-string-literal-operator-template"
|
||||
# pragma clang diagnostic ignored "-Wswitch-enum"
|
||||
#endif
|
||||
|
||||
#include "core.h"
|
||||
@ -1617,8 +1624,8 @@ FMT_CONSTEXPR unsigned parse_nonnegative_int(Iterator &it, ErrorHandler &&eh) {
|
||||
}
|
||||
|
||||
#if FMT_MSC_VER
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4512)
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable: 4512)
|
||||
#endif
|
||||
|
||||
template <typename Char, typename Context>
|
||||
@ -1639,7 +1646,7 @@ class custom_formatter: public function<bool> {
|
||||
};
|
||||
|
||||
#if FMT_MSC_VER
|
||||
#pragma warning(pop)
|
||||
# pragma warning(pop)
|
||||
#endif
|
||||
|
||||
template <typename T>
|
||||
@ -2564,8 +2571,8 @@ class basic_writer {
|
||||
|
||||
void on_num() {
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wundefined-func-template"
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wundefined-func-template"
|
||||
#endif
|
||||
unsigned num_digits = internal::count_digits(abs_value);
|
||||
char_type sep = internal::thousands_sep<char_type>(writer.locale_.get());
|
||||
@ -2573,7 +2580,7 @@ class basic_writer {
|
||||
writer.write_int(size, get_prefix(), spec,
|
||||
num_writer{abs_value, size, sep});
|
||||
#if FMT_CLANG_VERSION
|
||||
#pragma clang diagnostic pop
|
||||
# pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@ -19,7 +19,8 @@ environment:
|
||||
|
||||
matrix:
|
||||
allow_failures:
|
||||
- image: Visual Studio 2013
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013
|
||||
CMAKE_GENERATOR: Visual Studio 12 2013
|
||||
|
||||
init:
|
||||
- ps: |
|
||||
@ -28,12 +29,10 @@ init:
|
||||
}
|
||||
|
||||
before_build:
|
||||
# Workaround for CMake not wanting sh.exe on PATH for MinGW.
|
||||
- ps: |
|
||||
mkdir build
|
||||
cd build
|
||||
- mkdir build
|
||||
- cd build
|
||||
|
||||
cmake -G "$($env:CMAKE_GENERATOR)$($env:CMAKE_GENERATOR_SUFFIX)" -DFMT_WERROR=OFF -DFMT_PEDANTIC=ON -DCMAKE_BUILD_TYPE=$env:CONFIGURATION ..
|
||||
- ps: cmake -G "$($env:CMAKE_GENERATOR)$($env:CMAKE_GENERATOR_SUFFIX)" -DFMT_WERROR=OFF -DFMT_PEDANTIC=ON -DCMAKE_BUILD_TYPE=Debug ..
|
||||
|
||||
build:
|
||||
project: C:\projects\fmt\build\fmt.sln
|
||||
@ -42,8 +41,14 @@ build:
|
||||
|
||||
test_script:
|
||||
- ps: |
|
||||
cd build
|
||||
ctest -C $env:CONFIGURATION
|
||||
New-Item .\DartConfiguration.tcl -ItemType file
|
||||
ctest -C Debug -T Test
|
||||
$XSLInputElement = New-Object System.Xml.Xsl.XslCompiledTransform
|
||||
$XslInputElement.Load("https://raw.githubusercontent.com/rpavlik/jenkins-ctest-plugin/master/ctest-to-junit.xsl")
|
||||
$file = $(ls Testing\*\Test.xml) | Select -first 1
|
||||
$XSLInputElement.Transform((Resolve-Path $file), (Join-Path (Resolve-Path .) "ctest-to-junit-results.xml"))
|
||||
$wc = New-Object 'System.Net.WebClient'
|
||||
$wc.UploadFile("https://ci.appveyor.com/api/testresults/junit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .\ctest-to-junit-results.xml))
|
||||
|
||||
on_failure:
|
||||
- appveyor PushArtifact Testing/Temporary/LastTest.log
|
||||
|
||||
@ -86,7 +86,7 @@ test_build_dir = os.path.join(fmt_dir, "_build_test")
|
||||
# Configure library.
|
||||
makedirs_if_not_exist(build_dir)
|
||||
common_cmake_flags = [
|
||||
'-DCMAKE_INSTALL_PREFIX=' + install_dir, '-DCMAKE_BUILD_TYPE=' + build,
|
||||
'-DCMAKE_INSTALL_PREFIX=' + install_dir, '-DCMAKE_BUILD_TYPE=' + build
|
||||
]
|
||||
extra_cmake_flags = []
|
||||
if standard != '14':
|
||||
|
||||
Loading…
Reference in New Issue
Block a user