Skip to content
Snippets Groups Projects
Commit a34ac6fc authored by Marco Biasini's avatar Marco Biasini
Browse files

don't crash in absence of compounds.chemlib

parent 01113286
No related branches found
No related tags found
No related merge requests found
...@@ -455,10 +455,8 @@ BOOST_AUTO_TEST_CASE(seqres_import) ...@@ -455,10 +455,8 @@ BOOST_AUTO_TEST_CASE(seqres_import)
{ {
SetPrefixPath(getenv("OST_ROOT")); SetPrefixPath(getenv("OST_ROOT"));
String lib_path=GetSharedDataPath()+"/compounds.chemlib"; String lib_path=GetSharedDataPath()+"/compounds.chemlib";
conop::CompoundLibPtr compound_lib; conop::CompoundLibPtr compound_lib=conop::CompoundLib::Load(lib_path);
try { if (!compound_lib) {
compound_lib=conop::CompoundLib::Load(lib_path);
} catch(...) {
std::cout << "WARNING: skipping SEQRES import unit test. " std::cout << "WARNING: skipping SEQRES import unit test. "
<< "Rule-based builder is required" << std::endl; << "Rule-based builder is required" << std::endl;
return; return;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment