Package nl.siegmann.epublib.domain

Examples of nl.siegmann.epublib.domain.Resources


  public void testLoadResources_ZipFile() throws FileNotFoundException, IOException {
    // given
    ZipFile zipFile = new ZipFile(testBookFilename);
   
    // when
    Resources resources = ResourcesLoader.loadResources(zipFile, encoding);
   
    // then
    verifyResources(resources);
  }
View Full Code Here


  public void testLoadResources_ZipFile_lazy_all() throws FileNotFoundException, IOException {
    // given
    ZipFile zipFile = new ZipFile(testBookFilename);
   
    // when
    Resources resources = ResourcesLoader.loadResources(zipFile, encoding, Arrays.asList(MediatypeService.mediatypes));
   
    // then
    verifyResources(resources);
    Assert.assertEquals(Resource.class, resources.getById("container").getClass());
    Assert.assertEquals(LazyResource.class, resources.getById("book1").getClass());
  }
View Full Code Here

  public void testLoadResources_ZipFile_partial_lazy() throws FileNotFoundException, IOException {
    // given
    ZipFile zipFile = new ZipFile(testBookFilename);
   
    // when
    Resources resources = ResourcesLoader.loadResources(zipFile, encoding, Arrays.asList(MediatypeService.CSS));
   
    // then
    verifyResources(resources);
    Assert.assertEquals(Resource.class, resources.getById("container").getClass());
    Assert.assertEquals(LazyResource.class, resources.getById("book1").getClass());
    Assert.assertEquals(Resource.class, resources.getById("chapter1").getClass());
  }
View Full Code Here

TOP

Related Classes of nl.siegmann.epublib.domain.Resources

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.