@Test @Override public void testChromMT(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"MT", "41087870", "A", null}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(queriesMatch(br.getQuery(), query)); assertNotNull(br.getResponse()); }
@Test @Override public void testSpecificRefNotFound(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"1", "808922", "A", "hg38"}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(queriesMatch(br.getQuery(), query)); assertTrue(br.getResponse() == null || !br.getResponse()); }
@Test @Override public void testInvalidRef(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"1", "808922", "A", "hg100"}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(getNonMachingFields(br.getQuery(), query).size() == 1); assertEquals(br.getQuery().getReference(), null); assertNull(br.getResponse()); }
@Test @Override public void testInvalidChrom(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"30", "41087870", "A", null}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(getNonMachingFields(br.getQuery(), query).size() == 1); assertNull(br.getQuery().getChromosome()); assertNull(br.getResponse()); }
@Test @Override public void testAlleleConversion(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"14", "106833421", "DEL", null}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(getNonMachingFields(br.getQuery(), query).size() == 1); assertEquals(query[2].substring(0, 1), br.getQuery().getAllele()); assertNotNull(br.getResponse()); }
@Test @Override public void testChromConversion(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"chrom14", "106833421", "D", null}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue( (getNonMachingFields(br.getQuery(), query).size() == 1) && (getNonMachingFields(br.getQuery(), query).contains(0))); assertNotNull(br.getResponse()); }
@Test @Override public void testStringAllele(@ArquillianResource URL url) throws JAXBException, MalformedURLException { String[] query = {"22", "17213590", "TGTTA", null}; BeaconResponseTo br = readBeaconResponse(url.toExternalForm() + getUrl(BEACON, query)); assertNotNull(br); assertTrue(beaconsMatch(br.getBeacon(), BEACON)); assertTrue(queriesMatch(br.getQuery(), query)); // unsupported assertFalse(br.getResponse()); }