Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
temporary fix for NullPointerException in SymmetricFilterTest
- Loading branch information
knaas
committed
Mar 18, 2008
1 parent
755a066
commit c27b809
Showing
5 changed files
with
98 additions
and
109 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
symmetric/src/test/java/org/jumpmind/symmetric/web/MockNodeService.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/** | ||
* Copyright (C) 2005 Big Lots Inc. | ||
*/ | ||
|
||
package org.jumpmind.symmetric.web; | ||
|
||
public class MockNodeService extends org.jumpmind.symmetric.service.mock.MockNodeService | ||
{ | ||
static final String GOOD_SECURITY_TOKEN = "1"; | ||
|
||
static final String GOOD_NODE_ID = "1"; | ||
|
||
@Override | ||
public boolean isNodeAuthorized(String nodeId, String password) | ||
{ | ||
return GOOD_NODE_ID.equals(nodeId) && GOOD_SECURITY_TOKEN.equals(password); | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
symmetric/src/test/java/org/jumpmind/symmetric/web/MockRegistrationService.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/** | ||
* Copyright (C) 2005 Big Lots Inc. | ||
*/ | ||
|
||
package org.jumpmind.symmetric.web; | ||
|
||
public class MockRegistrationService extends org.jumpmind.symmetric.service.mock.MockRegistrationService | ||
{ | ||
public boolean isAutoRegistration() | ||
{ | ||
return true; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
symmetric/src/test/resources/org/jumpmind/symmetric/web/symmetric-web.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<beans xmlns="http://www.springframework.org/schema/beans" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> | ||
|
||
<import resource="classpath:/symmetric-properties.xml" /> | ||
<bean name="nodeService" class="org.jumpmind.symmetric.web.MockNodeService" /> | ||
<bean name="registrationService" class="org.jumpmind.symmetric.web.MockRegistrationService" /> | ||
<import resource="classpath:/symmetric-web.xml" /> | ||
</beans> |