use of org.eclipse.ceylon.cmr.api.ModuleSearchResult.ModuleDetails in project ceylon by eclipse.
the class SmokeTestCase method testCompleteOrg.
@Test
public void testCompleteOrg() throws Exception {
RepositoryManager manager = getRepositoryManager();
ModuleDetails[] expected = new ModuleDetails[] { com_acme_helloworld };
testComplete("com", expected, manager);
}
use of org.eclipse.ceylon.cmr.api.ModuleSearchResult.ModuleDetails in project ceylon by eclipse.
the class SmokeTestCase method testSearchJDKModulesPaged.
@Test
public void testSearchJDKModulesPaged() throws Exception {
Assume.assumeTrue(JDKUtils.jdk == JDKUtils.JDK.JDK8);
RepositoryManager repoManager = getJDKRepositoryManager();
// first page
ModuleDetails[] expected = new ModuleDetails[] { jdkModule("java.auth", "JDK module java.auth"), jdkModule("java.auth.kerberos", "JDK module java.auth.kerberos"), jdkModule("java.base", "JDK module java.base"), jdkModule("java.compiler", "JDK module java.compiler"), jdkModule("java.corba", "JDK module java.corba"), jdkModule("java.desktop", "JDK module java.desktop"), jdkModule("java.instrument", "JDK module java.instrument"), jdkModule("java.jdbc", "JDK module java.jdbc"), jdkModule("java.jdbc.rowset", "JDK module java.jdbc.rowset"), jdkModule("java.logging", "JDK module java.logging"), jdkModule("java.management", "JDK module java.management"), jdkModule("java.prefs", "JDK module java.prefs"), jdkModule("java.rmi", "JDK module java.rmi"), jdkModule("java.security.acl", "JDK module java.security.acl"), jdkModule("java.tls", "JDK module java.tls"), jdkModule("javafx.base", "JDK module javafx.base"), jdkModule("javafx.controls", "JDK module javafx.controls"), jdkModule("javafx.deploy", "JDK module javafx.deploy"), jdkModule("javafx.fxml", "JDK module javafx.fxml"), jdkModule("javafx.graphics", "JDK module javafx.graphics") };
ModuleSearchResult results = testSearchResults("", Type.JVM, expected, 0l, 20l, repoManager);
Assert.assertEquals(20, results.getCount());
Assert.assertEquals(true, results.getHasMoreResults());
Assert.assertEquals(0, results.getStart());
// second page
expected = new ModuleDetails[] { jdkModule("javafx.media", "JDK module javafx.media"), jdkModule("javafx.swing", "JDK module javafx.swing"), jdkModule("javafx.web", "JDK module javafx.web"), jdkModule("javax.annotation", "JDK module javax.annotation"), jdkModule("javax.jaxws", "JDK module javax.jaxws"), jdkModule("javax.naming", "JDK module javax.naming"), jdkModule("javax.script", "JDK module javax.script"), jdkModule("javax.transaction", "JDK module javax.transaction"), jdkModule("javax.xml", "JDK module javax.xml"), jdkModule("javax.xmldsig", "JDK module javax.xmldsig"), jdkModule("oracle.jdk.auth", "JDK module oracle.jdk.auth"), jdkModule("oracle.jdk.base", "JDK module oracle.jdk.base"), jdkModule("oracle.jdk.compat", "JDK module oracle.jdk.compat"), jdkModule("oracle.jdk.corba", "JDK module oracle.jdk.corba"), jdkModule("oracle.jdk.cosnaming", "JDK module oracle.jdk.cosnaming"), jdkModule("oracle.jdk.deploy", "JDK module oracle.jdk.deploy"), jdkModule("oracle.jdk.desktop", "JDK module oracle.jdk.desktop"), jdkModule("oracle.jdk.httpserver", "JDK module oracle.jdk.httpserver"), jdkModule("oracle.jdk.instrument", "JDK module oracle.jdk.instrument"), jdkModule("oracle.jdk.jaxp", "JDK module oracle.jdk.jaxp") };
results = testSearchResults("", Type.JVM, expected, results.getStart() + results.getCount(), 20l, repoManager, results.getNextPagingInfo());
Assert.assertEquals(20, results.getCount());
Assert.assertEquals(true, results.getHasMoreResults());
Assert.assertEquals(20, results.getStart());
// third page
expected = new ModuleDetails[] { jdkModule("oracle.jdk.jaxws", "JDK module oracle.jdk.jaxws"), jdkModule("oracle.jdk.jdbc.rowset", "JDK module oracle.jdk.jdbc.rowset"), jdkModule("oracle.jdk.jndi", "JDK module oracle.jdk.jndi"), jdkModule("oracle.jdk.logging", "JDK module oracle.jdk.logging"), jdkModule("oracle.jdk.management", "JDK module oracle.jdk.management"), jdkModule("oracle.jdk.management.iiop", "JDK module oracle.jdk.management.iiop"), jdkModule("oracle.jdk.rmi", "JDK module oracle.jdk.rmi"), jdkModule("oracle.jdk.scripting", "JDK module oracle.jdk.scripting"), jdkModule("oracle.jdk.sctp", "JDK module oracle.jdk.sctp"), jdkModule("oracle.jdk.security.acl", "JDK module oracle.jdk.security.acl"), jdkModule("oracle.jdk.smartcardio", "JDK module oracle.jdk.smartcardio"), jdkModule("oracle.jdk.tools.base", "JDK module oracle.jdk.tools.base"), jdkModule("oracle.jdk.tools.jaxws", "JDK module oracle.jdk.tools.jaxws"), jdkModule("oracle.jdk.tools.jre", "JDK module oracle.jdk.tools.jre"), jdkModule("oracle.jdk.xmldsig", "JDK module oracle.jdk.xmldsig"), jdkModule("oracle.sun.charsets", "JDK module oracle.sun.charsets") };
results = testSearchResults("", Type.JVM, expected, results.getStart() + results.getCount(), 20l, repoManager, results.getNextPagingInfo());
Assert.assertEquals(16, results.getCount());
Assert.assertEquals(false, results.getHasMoreResults());
Assert.assertEquals(40, results.getStart());
}
use of org.eclipse.ceylon.cmr.api.ModuleSearchResult.ModuleDetails in project ceylon by eclipse.
the class SmokeTestCase method testCompleteHello2JSNewModel.
@Test
public void testCompleteHello2JSNewModel() throws Exception {
RepositoryManager manager = getRepositoryManager();
ModuleDetails[] expected = new ModuleDetails[] { hello2_js };
testComplete("hello2", expected, manager, ModuleQuery.Type.JS);
}
use of org.eclipse.ceylon.cmr.api.ModuleSearchResult.ModuleDetails in project ceylon by eclipse.
the class SmokeTestCase method testCompleteJDK.
@Test
public void testCompleteJDK() throws Exception {
Assume.assumeTrue(JDKUtils.jdk == JDKUtils.JDK.JDK8);
RepositoryManager manager = getJDKRepositoryManager();
ModuleDetails[] expected = new ModuleDetails[] { jdkModule("java.auth", "JDK module java.auth"), jdkModule("java.auth.kerberos", "JDK module java.auth.kerberos"), jdkModule("java.base", "JDK module java.base"), jdkModule("java.compiler", "JDK module java.compiler"), jdkModule("java.corba", "JDK module java.corba"), jdkModule("java.desktop", "JDK module java.desktop"), jdkModule("java.instrument", "JDK module java.instrument"), jdkModule("java.jdbc", "JDK module java.jdbc"), jdkModule("java.jdbc.rowset", "JDK module java.jdbc.rowset"), jdkModule("java.logging", "JDK module java.logging"), jdkModule("java.management", "JDK module java.management"), jdkModule("java.prefs", "JDK module java.prefs"), jdkModule("java.rmi", "JDK module java.rmi"), jdkModule("java.security.acl", "JDK module java.security.acl"), jdkModule("java.tls", "JDK module java.tls"), jdkModule("javafx.base", "JDK module javafx.base"), jdkModule("javafx.controls", "JDK module javafx.controls"), jdkModule("javafx.deploy", "JDK module javafx.deploy"), jdkModule("javafx.fxml", "JDK module javafx.fxml"), jdkModule("javafx.graphics", "JDK module javafx.graphics"), jdkModule("javafx.media", "JDK module javafx.media"), jdkModule("javafx.swing", "JDK module javafx.swing"), jdkModule("javafx.web", "JDK module javafx.web"), jdkModule("javax.annotation", "JDK module javax.annotation"), jdkModule("javax.jaxws", "JDK module javax.jaxws"), jdkModule("javax.naming", "JDK module javax.naming"), jdkModule("javax.script", "JDK module javax.script"), jdkModule("javax.transaction", "JDK module javax.transaction"), jdkModule("javax.xml", "JDK module javax.xml"), jdkModule("javax.xmldsig", "JDK module javax.xmldsig"), jdkModule("oracle.jdk.auth", "JDK module oracle.jdk.auth"), jdkModule("oracle.jdk.base", "JDK module oracle.jdk.base"), jdkModule("oracle.jdk.compat", "JDK module oracle.jdk.compat"), jdkModule("oracle.jdk.corba", "JDK module oracle.jdk.corba"), jdkModule("oracle.jdk.cosnaming", "JDK module oracle.jdk.cosnaming"), jdkModule("oracle.jdk.deploy", "JDK module oracle.jdk.deploy"), jdkModule("oracle.jdk.desktop", "JDK module oracle.jdk.desktop"), jdkModule("oracle.jdk.httpserver", "JDK module oracle.jdk.httpserver"), jdkModule("oracle.jdk.instrument", "JDK module oracle.jdk.instrument"), jdkModule("oracle.jdk.jaxp", "JDK module oracle.jdk.jaxp"), jdkModule("oracle.jdk.jaxws", "JDK module oracle.jdk.jaxws"), jdkModule("oracle.jdk.jdbc.rowset", "JDK module oracle.jdk.jdbc.rowset"), jdkModule("oracle.jdk.jndi", "JDK module oracle.jdk.jndi"), jdkModule("oracle.jdk.logging", "JDK module oracle.jdk.logging"), jdkModule("oracle.jdk.management", "JDK module oracle.jdk.management"), jdkModule("oracle.jdk.management.iiop", "JDK module oracle.jdk.management.iiop"), jdkModule("oracle.jdk.rmi", "JDK module oracle.jdk.rmi"), jdkModule("oracle.jdk.scripting", "JDK module oracle.jdk.scripting"), jdkModule("oracle.jdk.sctp", "JDK module oracle.jdk.sctp"), jdkModule("oracle.jdk.security.acl", "JDK module oracle.jdk.security.acl"), jdkModule("oracle.jdk.smartcardio", "JDK module oracle.jdk.smartcardio"), jdkModule("oracle.jdk.tools.base", "JDK module oracle.jdk.tools.base"), jdkModule("oracle.jdk.tools.jaxws", "JDK module oracle.jdk.tools.jaxws"), jdkModule("oracle.jdk.tools.jre", "JDK module oracle.jdk.tools.jre"), jdkModule("oracle.jdk.xmldsig", "JDK module oracle.jdk.xmldsig"), jdkModule("oracle.sun.charsets", "JDK module oracle.sun.charsets") };
testComplete("", expected, manager);
}
use of org.eclipse.ceylon.cmr.api.ModuleSearchResult.ModuleDetails in project ceylon by eclipse.
the class SmokeTestCase method testCompleteComDot.
@Test
public void testCompleteComDot() throws Exception {
RepositoryManager manager = getRepositoryManager();
ModuleDetails[] expected = new ModuleDetails[] { com_acme_helloworld };
testComplete("com.", expected, manager);
}
Aggregations