aboutsummaryrefslogtreecommitdiffstats
path: root/tests/modtest.cpp
diff options
context:
space:
mode:
authordanglassey <danglassey>2002-10-22 13:01:49 +0000
committerdanglassey <danglassey>2002-10-22 13:01:49 +0000
commitcaba6ff484a20e8ddc2d4912f0edbbe9f926499c (patch)
treead16d42b45ac7d4ff93e63b95a4b273122dbc7fb /tests/modtest.cpp
parentd16a90fac71b7e403549e78d0f14d4de9ad65111 (diff)
downloadsword-sf-cvs-caba6ff484a20e8ddc2d4912f0edbbe9f926499c.tar.gz
sync with crosswire 20021022-1300
Diffstat (limited to 'tests/modtest.cpp')
-rw-r--r--tests/modtest.cpp25
1 files changed, 7 insertions, 18 deletions
diff --git a/tests/modtest.cpp b/tests/modtest.cpp
index 37daabf..d3bd701 100644
--- a/tests/modtest.cpp
+++ b/tests/modtest.cpp
@@ -8,24 +8,13 @@ using namespace sword;
int main(int argc, char **argv) {
SWMgr mymgr;
ModMap::iterator it;
- SWModule *module;
+ SWModule *module = mymgr.Modules["RWP"];
+ VerseKey parser;
+ ListKey lk = parser.ParseVerseList("mal4:6-rev", parser, true);
+ lk.Persist(1);
+ module->SetKey(lk);
- for (it = mymgr.Modules.begin(); it != mymgr.Modules.end(); it++) {
- module = it->second;
- if (!strcmp(module->Type(), "Biblical Texts")) {
- std::cout << module->Name() << "\n";
- for (*module = TOP; (!module->Key().Error()); ((VerseKey *)&module->Key())->Book(((VerseKey *)&module->Key())->Book()+1)) {
- std::cout << module->KeyText() << "\n";
- }
- }
-
- if (!strcmp(module->Type(), "Commentaries")) {
- std::cout << module->Name() << "\n";
- for (*module = TOP; (!module->Error()); (*module)--) {
- std::cout << module->KeyText() << "\n";
- }
-
- }
- }
+ (*module) = TOP;
+ std::cout << module->KeyText() << "\n";
return 0;
}