SlicerFactory { @NotNull public static Slicer fromBedFile(@NotNull String bedFile) throws IOException { return new BidirectionalSlicer(BEDFileLoader.fromBedFile(bedFile)); } private  SlicerFactory(); @NotNull static Slicer fromBedFile(@NotNull String bedFile);  }
@Test public void handleTrivialBed() throws IOException { final Slicer slicer = SlicerFactory.fromBedFile(VALID_BED); assertTrue(slicer.includes(new TestGenomePosition("1", 1))); assertFalse(slicer.includes(new TestGenomePosition("1", 2))); }
@Test public void handleUnsortedBed() throws IOException { final Slicer slicer = SlicerFactory.fromBedFile(UNSORTED_BED); assertEquals(2, slicer.regions().size()); }
@Test public void handleInvalidBedRegion() throws IOException { final Slicer slicer = SlicerFactory.fromBedFile(INVALID_BED); assertEquals(2, slicer.regions().size()); }