This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[v3] Add 27_io/filebuf_members.cc testcase
- From: Paolo Carlini <pcarlini at unitus dot it>
- To: gcc-patches at gcc dot gnu dot org
- Cc: CGLeggett at lbl dot gov
- Date: Mon, 28 Jan 2002 21:17:48 +0100
- Subject: [v3] Add 27_io/filebuf_members.cc testcase
Hi,
I have committed the following new testcase, originally conceived, in an
extended form, by Charles Leggett.
Tested i686-pc-linux-gnu, approved by Benjamin Kosnik.
Cheers,
Paolo.
/////////////
2002-01-28 Paolo Carlini <pcarlini@unitus.it>
Charles Leggett <CGLeggett@lbl.gov>
* testsuite/27_io/filebuf_members.cc (test_05): Add test.
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/testsuite/27_io/filebuf_members.cc,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- gcc/libstdc++-v3/testsuite/27_io/filebuf_members.cc 2002/01/26 01:55:09
1.13
+++ gcc/libstdc++-v3/testsuite/27_io/filebuf_members.cc 2002/01/28 20:07:57
1.14
@@ -174,6 +174,22 @@
exit(0);
}
+// Charles Leggett <CGLeggett@lbl.gov>
+void test_05()
+{
+ bool test = true;
+
+ std::fstream scratch_file;
+
+ scratch_file.open("SCRATCH", std::ios::out);
+ scratch_file.close();
+
+ scratch_file.open("SCRATCH", std::ios::in);
+ scratch_file.close();
+
+ VERIFY(scratch_file);
+}
+
int
main()
{
@@ -181,6 +197,7 @@
test_02();
test_03();
test_04();
+ test_05();
return 0;
}