diff options
author | ctice <ctice@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-09-08 23:35:14 +0000 |
---|---|---|
committer | ctice <ctice@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-09-08 23:35:14 +0000 |
commit | 786f817740a7dca966e5f49b0b4976b32d0be744 (patch) | |
tree | 7aed39930d05ef1f28db4df7227d5b55ec792763 /libvtv/testsuite/libvtv.cc/parts-test-main.cpp | |
parent | 1eadcdffcb14af40bebaec65de4bf7ef75756164 (diff) | |
download | gcc-786f817740a7dca966e5f49b0b4976b32d0be744.tar.gz |
Update libvtv testsuite so that most of the tests now run under
the dejagnu test harness.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@202373 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libvtv/testsuite/libvtv.cc/parts-test-main.cpp')
-rw-r--r-- | libvtv/testsuite/libvtv.cc/parts-test-main.cpp | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/libvtv/testsuite/libvtv.cc/parts-test-main.cpp b/libvtv/testsuite/libvtv.cc/parts-test-main.cpp new file mode 100644 index 00000000000..a0cc721abf5 --- /dev/null +++ b/libvtv/testsuite/libvtv.cc/parts-test-main.cpp @@ -0,0 +1,39 @@ +// { dg-do run } + +#include "parts-test-main.h" +#include "parts-test-extra-parts-views.h" + +MainParts::MainParts () {} + +MainParts::~MainParts () +{ + for (int i = static_cast<int>(main_extra_parts_.size()) - 1; i >= 0; --i) + delete main_extra_parts_[i]; + main_extra_parts_.clear(); +} + +void +MainParts::AddParts (ExtraParts *parts) +{ + main_extra_parts_.push_back (parts); +} + + +void +MainParts::PreEarlyInitialization (void) +{ + for (int i = 0; i < main_extra_parts_.size(); ++i) + main_extra_parts_[i]->PreEarlyInitialization (); +} + + +int +main (int argc, char **argv) +{ + MainParts *main_parts = new MainParts (); + + main_parts->AddParts (new ExtraPartsViews ()); + main_parts->PreEarlyInitialization (); + + return 0; +} |