diff options
author | Steinar H. Gunderson <sesse@google.com> | 2015-06-22 15:45:11 +0200 |
---|---|---|
committer | Steinar H. Gunderson <sesse@google.com> | 2015-06-22 16:09:56 +0200 |
commit | e7a897e187e90b33f87bd9e64872cf561de9ebca (patch) | |
tree | 5a6b9700ddd67a404e8de20ba13644ece47dbc6b /snappy-test.cc | |
parent | 86eb8b152bdb065ad11bf331a9f7d65b72616acf (diff) | |
download | snappy-git-e7a897e187e90b33f87bd9e64872cf561de9ebca.tar.gz |
Fixed unit tests to compile under MSVC.
1. Including config.h in test.
2. Including windows.h before zippy-test.h.
3. Removed definition of WIN32_LEAN_AND_MEAN. This caused problems in
build environments that define WIN32_LEAN_AND_MEAN as our
definition didn't check for prior existence. This constant is old
and no longer needed anyhow.
4. Disable MSVC warning 4722 since ~LogMessageCrash() never returns.
A=cmumford
R=jeff
Diffstat (limited to 'snappy-test.cc')
-rw-r--r-- | snappy-test.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/snappy-test.cc b/snappy-test.cc index 4619410..7f1d0a8 100644 --- a/snappy-test.cc +++ b/snappy-test.cc @@ -28,13 +28,16 @@ // // Various stubs for the unit tests for the open-source version of Snappy. -#include "snappy-test.h" +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif #ifdef HAVE_WINDOWS_H -#define WIN32_LEAN_AND_MEAN #include <windows.h> #endif +#include "snappy-test.h" + #include <algorithm> DEFINE_bool(run_microbenchmarks, true, |