Added conditional compiles around the "using namespace" per author recommendation.

This commit is contained in:
Alexis Denis 2016-11-20 09:58:41 -06:00
parent 2809901115
commit 6c62f24bfd
8 changed files with 16 additions and 0 deletions

View file

@ -4,7 +4,9 @@
#include "ScopedCurrentTest.h"
using namespace std;
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
namespace {

View file

@ -2,7 +2,9 @@
#include "UnitTest++/CurrentTest.h"
#include "ScopedCurrentTest.h"
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
namespace
{

View file

@ -9,7 +9,9 @@
#include <stdexcept>
using namespace std;
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
namespace {

View file

@ -2,7 +2,9 @@
#include "UnitTest++/UnitTestPP.h"
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
// This file is not intended to test every little thing, just a few basics to hopefully ensure
// the macros are working and the short macros are not defined.

View file

@ -4,7 +4,9 @@
#include "ScopedCurrentTest.h"
using namespace std;
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
#ifndef UNITTEST_NO_EXCEPTIONS

View file

@ -1,6 +1,8 @@
#include "UnitTest++/UnitTestPP.h"
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
// We're really testing if it's possible to use the same suite in two files
// to compile and link successfuly (TestTestSuite.cpp has suite with the same name)

View file

@ -4,7 +4,9 @@
#include "RecordingReporter.h"
#include "ScopedCurrentTest.h"
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
namespace {

View file

@ -2,7 +2,9 @@
#include "ScopedCurrentTest.h"
// These are sample tests that show the different features of the framework
#ifdef __BORLANDC__
using namespace UnitTest;
#endif
namespace {