summaryrefslogtreecommitdiff
path: root/decoder/parser_test.cc
diff options
context:
space:
mode:
authorChris Dyer <cdyer@cs.cmu.edu>2012-05-02 02:30:52 -0400
committerChris Dyer <cdyer@cs.cmu.edu>2012-05-02 02:30:52 -0400
commit1c32f3e2831aefdf50fd226d3e1b314c804afc3b (patch)
tree69c07b672f279f69c12525fde02fa2675e63ea6f /decoder/parser_test.cc
parent721ff772038c117da8746836533609eda7737443 (diff)
remove dependency on gtest, remove all-static
Diffstat (limited to 'decoder/parser_test.cc')
-rw-r--r--decoder/parser_test.cc21
1 files changed, 5 insertions, 16 deletions
diff --git a/decoder/parser_test.cc b/decoder/parser_test.cc
index da1fbd89..e2916e44 100644
--- a/decoder/parser_test.cc
+++ b/decoder/parser_test.cc
@@ -1,8 +1,7 @@
-#include <cassert>
-#include <iostream>
-#include <fstream>
-#include <vector>
-#include <gtest/gtest.h>
+#define BOOST_TEST_MODULE ParseTest
+#include <boost/test/unit_test.hpp>
+#include <boost/test/floating_point_comparison.hpp>
+#include "lattice.h"
#include "hg.h"
#include "trule.h"
#include "bottom_up_parser.h"
@@ -10,13 +9,7 @@
using namespace std;
-class ChartTest : public testing::Test {
- protected:
- virtual void SetUp() { }
- virtual void TearDown() { }
-};
-
-TEST_F(ChartTest,LanguageModel) {
+BOOST_AUTO_TEST_CASE(Parse) {
LatticeArc a(TD::Convert("ein"), 0.0, 1);
LatticeArc b(TD::Convert("haus"), 0.0, 1);
Lattice lattice(2);
@@ -29,7 +22,3 @@ TEST_F(ChartTest,LanguageModel) {
parser.Parse(lattice, &forest);
}
-int main(int argc, char **argv) {
- testing::InitGoogleTest(&argc, argv);
- return RUN_ALL_TESTS();
-}