use of org.jboss.tools.hibernate.search.property.testers.OneParentConfigPropertyTester in project jbosstools-hibernate by jbosstools.
the class OneParentConfigPropertyTesterTest method testSameConfig.
@Test
public void testSameConfig() {
ConsoleConfiguration consoleConfiguration = mock(ConsoleConfiguration.class);
TreePath treePath1 = new TreePath(new Object[] { consoleConfiguration });
TreePath treePath2 = new TreePath(new Object[] { consoleConfiguration });
ITreeSelection receiver = new TreeSelection(new TreePath[] { treePath1, treePath2 });
OneParentConfigPropertyTester propertyTester = new OneParentConfigPropertyTester();
assertTrue(propertyTester.test(receiver, "doesn't matter", null, null));
}
use of org.jboss.tools.hibernate.search.property.testers.OneParentConfigPropertyTester in project jbosstools-hibernate by jbosstools.
the class OneParentConfigPropertyTesterTest method testDifferentConfigs.
@Test
public void testDifferentConfigs() {
ConsoleConfiguration consoleConfiguration1 = mock(ConsoleConfiguration.class);
ConsoleConfiguration consoleConfiguration2 = mock(ConsoleConfiguration.class);
TreePath treePath1 = new TreePath(new Object[] { consoleConfiguration1 });
TreePath treePath2 = new TreePath(new Object[] { consoleConfiguration2 });
ITreeSelection receiver = new TreeSelection(new TreePath[] { treePath1, treePath2 });
OneParentConfigPropertyTester propertyTester = new OneParentConfigPropertyTester();
assertFalse(propertyTester.test(receiver, "doesn't matter", null, null));
}
Aggregations