### Question:
ImportDb { protected Node nodeByCanonical(String canonical) throws NotUniqueException { try { return Iterators .singleOrNull(dao.getNeo().findNodes(Labels.TAXON, NeoProperties.CANONICAL_NAME, canonical)); } catch (NoSuchElementException e) { throw new NotUniqueException(canonical, "Canonical name not unique: " + canonical); } } ImportDb(UUID datasetKey, UsageDao dao); UUID getDatasetKey();  }### Answer:
@Test public void testNodeByCanonical() throws Exception { try(Transaction tx = dao.beginTx()) { assertNull(idb.nodeByCanonical("Abies")); Node n = create("312", "Abies", "Abies Mill."); tx.success(); assertEquals(n, idb.nodeByCanonical("Abies")); assertNull(idb.nodeByCanonical("Abiess")); } }