Boost logo

Boost-Commit :

From: jeff_at_[hidden]
Date: 2007-07-31 00:48:08


Author: jefffaust
Date: 2007-07-31 00:48:07 EDT (Tue, 31 Jul 2007)
New Revision: 7609
URL: http://svn.boost.org/trac/boost/changeset/7609

Log:
add columnated test
Added:
   sandbox/explore/libs/explore/test/columnated.cpp (contents, props changed)
Text files modified:
   sandbox/explore/libs/explore/test/Jamfile.v2 | 15 ++++++++-------
   1 files changed, 8 insertions(+), 7 deletions(-)

Modified: sandbox/explore/libs/explore/test/Jamfile.v2
==============================================================================
--- sandbox/explore/libs/explore/test/Jamfile.v2 (original)
+++ sandbox/explore/libs/explore/test/Jamfile.v2 2007-07-31 00:48:07 EDT (Tue, 31 Jul 2007)
@@ -1,4 +1,4 @@
-# Boost.Print Library
+# Boost.Print Library
 
 # Copyright Jared McIntyre 2007. Use, modification and
 # distribution is subject to the Boost Software License, Version
@@ -10,13 +10,13 @@
 # bring in rules for testing
 import testing ;
 
-project
+project
     : source-location .
     : requirements
     ;
 {
   test-suite printing
- :
+ :
   [ run simple_types.cpp ]
   [ run c_array.cpp ]
   [ run user_defined_container.cpp ]
@@ -27,17 +27,18 @@
   [ run std_map.cpp ]
   [ run std_set.cpp ]
   [ run std_pair.cpp ]
-
+
   [ run boost_array.cpp ]
   [ run boost_tuple.cpp ]
   [ run boost_variant.cpp ]
-
+
   [ run boost_range.cpp ]
-
+
   [ run custom_format_simple.cpp ]
   [ run html_table_output.cpp ]
   [ run multi_dim_test.cpp ]
-
+
   [ run is_assoc_iter.cpp ]
+ [ run columnated.cpp ]
  ;
 }

Added: sandbox/explore/libs/explore/test/columnated.cpp
==============================================================================
--- (empty file)
+++ sandbox/explore/libs/explore/test/columnated.cpp 2007-07-31 00:48:07 EDT (Tue, 31 Jul 2007)
@@ -0,0 +1,39 @@
+// Boost.Print library
+
+// Copyright Jeffrey Faust 2007. Use, modification and
+// distribution is subject to the Boost Software License, Version
+// 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+// For more information, see http://www.boost.org
+
+#define BOOST_TEST_MODULE PrintLib
+#include <boost/test/unit_test.hpp>
+#include <string>
+#include <sstream>
+#include <vector>
+#include "../../../boost/explore.hpp"
+
+BOOST_AUTO_TEST_CASE( basic_array_print_test )
+{
+ BOOST_FAIL("Test not implemented");
+}
+
+BOOST_AUTO_TEST_CASE( basic_array_stream_test )
+{
+ using namespace explore;
+ std::stringstream str_out;
+ std::vector<int> vi;
+
+ for( int i = 0; i < 9; ++i )
+ {
+ vi.push_back(i);
+ }
+
+ str_out << setrows(3) << start("") << explore::end("") << vi;
+
+ BOOST_CHECK_EQUAL(str_out.str(),
+ "0, 1, 2, \n"
+ "3, 4, 5, \n"
+ "6, 7, 8");
+}


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk