gtest_xml_outfile2_test_.cc revision 1be2c9def7187e4e643c00a31dd9986395795d7d
1b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// Copyright 2008, Google Inc. 2b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// All rights reserved. 38393335b955da7340c9f19b1b4b2d6c0c2c04be7Craig Cornelius// 4b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// Redistribution and use in source and binary forms, with or without 5b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// modification, are permitted provided that the following conditions are 6b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// met: 7b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// 8b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// * Redistributions of source code must retain the above copyright 9b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// notice, this list of conditions and the following disclaimer. 10b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// * Redistributions in binary form must reproduce the above 11b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// copyright notice, this list of conditions and the following disclaimer 12b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// in the documentation and/or other materials provided with the 13b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// distribution. 14b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// * Neither the name of Google Inc. nor the names of its 15b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// contributors may be used to endorse or promote products derived from 16b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// this software without specific prior written permission. 17b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// 18b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queru// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 2659d709d503bab6e2b61931737e662dd293b40578ccornelius// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queru// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 2950294ead5e5d23f5bbfed76e00e6b510bd41eee1claireho// 30b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queru// Author: keith.ray@gmail.com (Keith Ray) 3159d709d503bab6e2b61931737e662dd293b40578ccornelius// 3259d709d503bab6e2b61931737e662dd293b40578ccornelius// gtest_xml_outfile2_test_ writes some xml via TestProperty used by 3359d709d503bab6e2b61931737e662dd293b40578ccornelius// gtest_xml_outfiles_test.py 3459d709d503bab6e2b61931737e662dd293b40578ccornelius 3559d709d503bab6e2b61931737e662dd293b40578ccornelius#include <gtest/gtest.h> 36b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queru 37b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queruclass PropertyTwo : public testing::Test { 38b0ac937921a2c196d8b9da665135bf6ba01a1ccfJean-Baptiste Queru protected: 39b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru virtual void SetUp() { 40b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho RecordProperty("SetUpProp", 2); 41b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho } 42b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho virtual void TearDown() { 43b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho RecordProperty("TearDownProp", 2); 44b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho } 45b26ce3a7367e4ed2ee7ddddcdc3f3d3377a455c2claireho}; 46b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru 47b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste QueruTEST_F(PropertyTwo, TestSomeProperties) { 48b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru RecordProperty("TestSomeProperty", 2); 49b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru} 50b13da9df870a61b11249bf741347908dbea0edd8Jean-Baptiste Queru