Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions src/org/labkey/test/tests/AdvancedImportOptionsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ public class AdvancedImportOptionsTest extends BaseWebDriverTest implements Post
private static final boolean EXPECTED_IMPORT_ERRORS = false;
private static final int EXPECTED_COMPLETED_IMPORT_JOBS = 1;
private static final int EXPECTED_COMPLETED_MULTI_FOLDER_JOBS = 2;
private Boolean _studyDesignPreviouslyEnabled;
private Boolean _advancedImportOptionsEnabled;

@Override
Expand All @@ -96,7 +95,6 @@ protected BrowserType bestBrowser()
public static void doSetup()
{
AdvancedImportOptionsTest test = getCurrentTest();
test._studyDesignPreviouslyEnabled = OptionalFeatureHelper.enableOptionalFeature(test.createDefaultConnection(), "studyDesignFlag");
test._advancedImportOptionsEnabled = OptionalFeatureHelper.enableOptionalFeature(test.createDefaultConnection(), "advancedImportFlag");
}

Expand All @@ -108,8 +106,6 @@ public void doCleanup(boolean afterTest) throws TestTimeoutException
_containerHelper.deleteProject(IMPORT_PROJECT_FILE02, false);
_containerHelper.deleteProject(IMPORT_PROJECT_FILE03, false);
_containerHelper.deleteProject(IMPORT_PROJECT_MULTI, false);
if (_studyDesignPreviouslyEnabled != null)
OptionalFeatureHelper.setOptionalFeature(createDefaultConnection(), "studyDesignFlag", _studyDesignPreviouslyEnabled);

if (_advancedImportOptionsEnabled != null)
OptionalFeatureHelper.setOptionalFeature(createDefaultConnection(), "advancedImportFlag", _advancedImportOptionsEnabled);
Expand Down
13 changes: 8 additions & 5 deletions src/org/labkey/test/util/StudyHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -561,15 +561,18 @@ public void setupRepositoryType(boolean advanced, boolean editable, boolean requ
public boolean isSpecimenModulePresent()
{
if (null == _specimenModulePresent)
{
AbstractContainerHelper containerHelper = new APIContainerHelper(_test);
Set<String> allModules = containerHelper.getAllModules();
_specimenModulePresent = allModules.contains("specimen");
}
_specimenModulePresent = isModulePresent("specimen");

return _specimenModulePresent;
}

public boolean isModulePresent(String moduleName)
{
AbstractContainerHelper containerHelper = new APIContainerHelper(_test);
Set<String> allModules = containerHelper.getAllModules();
return allModules.contains(moduleName);
}

public boolean isSpecimenModuleActive()
{
if (!isSpecimenModulePresent())
Expand Down