@Test
void load() {

    ServiceLoader loader = new ServiceLoader();
    Bundle bundle = new Bundle();
    Folder folder = new Folder();
    folder.setId(TEST_FOLDER);
    folder.setName(TEST_FOLDER);
    folder.setPath(TEST_FOLDER);
    bundle.getFolders().put(TEST_FOLDER, folder);
    loader.load(bundle, createServiceXml(DocumentTools.INSTANCE.getDocumentBuilder().newDocument(),
            true, false, false, false, false));
    assertFalse(bundle.getServices().isEmpty());
    assertEquals(1, bundle.getServices().size());
    Service service = bundle.getServices().get(TEST_FOLDER + "/service");
    assertNotNull(service);
    assertEquals("service", service.getName());
    assertEquals("/service", service.getUrl());
    assertEquals("id", service.getId());
    assertNotNull(service.getServiceDetailsElement());
    assertFalse(service.getHttpMethods().isEmpty());
    assertEquals(4, service.getHttpMethods().size());
    assertTrue(service.getHttpMethods().containsAll(Arrays.asList("GET", "POST", "PUT", "DELETE")));
    assertNotNull(service.getParentFolder());
    assertEquals("folder", service.getParentFolder().getId());
    assertEquals("policy", service.getPolicy());
    Map<String, Object> expected = new HashMap<>();
    expected.put("prop", "value");
    expected.put("ENV.prop", null);
    assertPropertiesContent(expected, service.getProperties());
}