Skip to content

Commit

Permalink
move test namespace into our cnd
Browse files Browse the repository at this point in the history
  • Loading branch information
cbeer committed Jun 12, 2013
1 parent d684999 commit 5f087c1
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 11 deletions.
10 changes: 0 additions & 10 deletions fcrepo-http-commons/src/main/java/org/fcrepo/AbstractResource.java
Expand Up @@ -51,10 +51,6 @@ public abstract class AbstractResource {

private static final Logger LOGGER = getLogger(AbstractResource.class);

public static final String TEST_NS_PREFIX = "test";

public static final String TEST_NS_URI = "info:fedora/test/";

/**
* Useful for constructing URLs
*/
Expand Down Expand Up @@ -109,12 +105,6 @@ public abstract class AbstractResource {
@PostConstruct
public void initialize() throws RepositoryException {

final Session testSession = sessions.getSession();
NamespaceTools.getNamespaceRegistry(testSession).registerNamespace(
TEST_NS_PREFIX, TEST_NS_URI);
testSession.save();
testSession.logout();

}

/**
Expand Down
Expand Up @@ -53,7 +53,6 @@ public void testInitialize() throws RepositoryException {
when(mockSessions.getSession()).thenReturn(mockSession);
testObj.setSessionFactory(mockSessions);
testObj.initialize();
verify(mockNames).registerNamespace(AbstractResource.TEST_NS_PREFIX, AbstractResource.TEST_NS_URI);
}

@Test
Expand Down
1 change: 1 addition & 0 deletions fcrepo-kernel/src/main/resources/fedora-node-types.cnd
Expand Up @@ -26,6 +26,7 @@

<fedorarelsext = 'info:fedora/fedora-system:def/relations-external#'>

<test = 'info:fedora/test/'>

[fedora:relations] mixin

Expand Down

0 comments on commit 5f087c1

Please sign in to comment.