@Override
 public void initialSetup() throws CoreException {
   TestingUtilities.importModelUsingWizard(
       m_sys, m_workspace_path + "/models/pre-716-test-models/pre-716-test-model.xtuml", false);
   BaseTest.dispatchEvents(0);
   m_sys = getSystemModel(getProject().getName());
 }
  @Override
  protected void setUp() throws Exception {
    if (!initialized) {
      super.setUp();
      final IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);

      loadProject(projectName);

      m_sys =
          SystemModel_c.SystemModelInstance(
              Ooaofooa.getDefaultInstance(),
              new ClassQueryInterface_c() {

                public boolean evaluate(Object candidate) {
                  return ((SystemModel_c) candidate).getName().equals(project.getName());
                }
              });

      m_sys.getPersistableComponent().loadComponentAndChildren(new NullProgressMonitor());

      dispatchEvents(0);

      initialized = true;
    }
  }
 public void tearDown() throws Exception {
   super.tearDown();
   if (getName().contains(StaticTestName)) {
     String msg = getName() + " #" + test_id + " with " + testModel.getName();
     if (testMCModelConsistencyPassed) {
       msg = msg + " (passed)";
     } else {
       msg = "Error! " + msg + " (failed)";
     }
     System.out.println(msg);
   }
 }
 protected void setUp() throws Exception {
   super.setUp();
   if (!initialized) {
     m_sys = getSystemModel("Models");
     ensureAvailableAndLoaded(
         "Models", "Imported Component IF Scope Testing", false, true, "Component Package");
     Ooaofooa componentRoot = modelRoot;
     ensureAvailableAndLoaded("Models", "sdt_test", false, false, "Domain");
     testDomain = Domain_c.DomainInstance(modelRoot);
     modelRoot = componentRoot;
     initialized = true;
   }
   CorePlugin.disableParseAllOnResourceChange();
 }
  public void testMCModelConsistency() throws Exception {
    testMCModelConsistencyPassed = false;
    test_id = String.valueOf(modelNumber + 1);
    EclipseOoaofooa.setPersistEnabled(true);
    final String fileName = testModel.getName();
    this.loadProject(fileName);
    SystemModel_c system =
        SystemModel_c.SystemModelInstance(
            Ooaofooa.getDefaultInstance(),
            new ClassQueryInterface_c() {
              public boolean evaluate(Object candidate) {
                return ((SystemModel_c) candidate).getName().equals(fileName);
              }
            });
    BaseTest.dispatchEvents(0);

    modelRoot.checkDomainConsistency();

    // Graphics cannot be checked until Bugzilla 1156 has been
    // addressed.
    // OoaofgraphicsUtil.checkGraphicsConsistency(modelRoot.getId());

    testMCModelConsistencyPassed = true;
  }
 public void setUp() throws Exception {
   super.setUp();
   Ooaofooa.setPersistEnabled(true);
 }
  @Override
  protected void setUp() throws Exception {
    if (!initialized) delayGlobalUpgrade = true;
    super.setUp();

    if (!initialized) {
      CorePlugin.disableParseAllOnResourceChange();

      // set perspective switch dialog on launch
      DebugUIPlugin.getDefault()
          .getPluginPreferences()
          .setValue(IDebugUIConstants.PLUGIN_ID + ".switch_to_perspective", "always");

      CorePlugin.getDefault()
          .getPluginPreferences()
          .setDefault(BridgePointPreferencesStore.ALLOW_IMPLICIT_COMPONENT_ADDRESSING, true);

      CorePlugin.getDefault()
          .getPluginPreferences()
          .setValue(BridgePointPreferencesStore.SHOW_EVENT_PARAMETERS, true);

      // initialize test model
      final IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);

      File sourceProject = new File(m_workspace_path + "../" + projectName);

      TestingUtilities.copyProjectContents(sourceProject, project);

      TestingUtilities.allowJobCompletion();

      TestingUtilities.allowJobCompletion();

      m_sys =
          SystemModel_c.SystemModelInstance(
              Ooaofooa.getDefaultInstance(),
              new ClassQueryInterface_c() {

                public boolean evaluate(Object candidate) {
                  return ((SystemModel_c) candidate).getName().equals(project.getName());
                }
              });

      PersistableModelComponent sys_comp = m_sys.getPersistableComponent();
      sys_comp.loadComponentAndChildren(new NullProgressMonitor());

      CorePlugin.enableParseAllOnResourceChange();

      TestingUtilities.allowJobCompletion();
      while (!ResourcesPlugin.getWorkspace().getRoot().isSynchronized(IProject.DEPTH_INFINITE)) {
        ResourcesPlugin.getWorkspace()
            .getRoot()
            .refreshLocal(IProject.DEPTH_INFINITE, new NullProgressMonitor());
        while (PlatformUI.getWorkbench().getDisplay().readAndDispatch()) ;
      }

      Ooaofooa.setPersistEnabled(true);
      delayGlobalUpgrade = false;

      initialized = true;
    }
  }