diff options
Diffstat (limited to 'security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc')
-rw-r--r-- | security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc b/security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc index 43d8e5777..d8a8788c6 100644 --- a/security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc +++ b/security/nss/gtests/google_test/gtest/samples/sample5_unittest.cc @@ -26,8 +26,7 @@ // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) + // This sample teaches how to reuse a test fixture in multiple test // cases by deriving sub-fixtures from it. @@ -46,10 +45,10 @@ #include <limits.h> #include <time.h> -#include "sample3-inl.h" #include "gtest/gtest.h" #include "sample1.h" - +#include "sample3-inl.h" +namespace { // In this sample, we want to ensure that every test finishes within // ~5 seconds. If a test takes longer to run, we consider it a // failure. @@ -191,7 +190,7 @@ TEST_F(QueueTest, Dequeue) { EXPECT_EQ(1u, q2_.Size()); delete n; } - +} // namespace // If necessary, you can derive further test fixtures from a derived // fixture itself. For example, you can derive another fixture from // QueueTest. Google Test imposes no limit on how deep the hierarchy |