summaryrefslogtreecommitdiff
path: root/smccSTAL/src
diff options
context:
space:
mode:
authormcentner <mcentner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2009-07-01 13:03:41 +0000
committermcentner <mcentner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2009-07-01 13:03:41 +0000
commit6cb4a071eab9a3b8cf78b8ec7e407aa148f2d038 (patch)
tree762855c70893eaac8b0f944cdabebc115849aae2 /smccSTAL/src
parente7641b2b5861897e1e1abab3b7411bb77361d5cb (diff)
downloadmocca-6cb4a071eab9a3b8cf78b8ec7e407aa148f2d038.tar.gz
mocca-6cb4a071eab9a3b8cf78b8ec7e407aa148f2d038.tar.bz2
mocca-6cb4a071eab9a3b8cf78b8ec7e407aa148f2d038.zip
Major refactoring of SMCC
git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@381 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4
Diffstat (limited to 'smccSTAL/src')
-rw-r--r--smccSTAL/src/main/java/at/gv/egiz/bku/smccstal/InfoBoxReadRequestHandler.java4
-rw-r--r--smccSTAL/src/test/java/at/gv/egiz/smcc/AbstractSMCCSTALTest.java35
2 files changed, 9 insertions, 30 deletions
diff --git a/smccSTAL/src/main/java/at/gv/egiz/bku/smccstal/InfoBoxReadRequestHandler.java b/smccSTAL/src/main/java/at/gv/egiz/bku/smccstal/InfoBoxReadRequestHandler.java
index eeb97290..32e990c5 100644
--- a/smccSTAL/src/main/java/at/gv/egiz/bku/smccstal/InfoBoxReadRequestHandler.java
+++ b/smccSTAL/src/main/java/at/gv/egiz/bku/smccstal/InfoBoxReadRequestHandler.java
@@ -53,8 +53,8 @@ public class InfoBoxReadRequestHandler extends AbstractRequestHandler {
.getCardPINProvider(),
infoBox.getDomainIdentifier());
if (resp == null) {
- log.info("Got null as result->user cancelled");
- return new ErrorResponse(6001);
+ log.info("Infobox doesn't contain any data. Assume card is not activated.");
+ throw new NotActivatedException();
} else {
try {
resp = DomainIdConverter.convertDomainId(resp, infoBox
diff --git a/smccSTAL/src/test/java/at/gv/egiz/smcc/AbstractSMCCSTALTest.java b/smccSTAL/src/test/java/at/gv/egiz/smcc/AbstractSMCCSTALTest.java
index 1c1cb833..36880e68 100644
--- a/smccSTAL/src/test/java/at/gv/egiz/smcc/AbstractSMCCSTALTest.java
+++ b/smccSTAL/src/test/java/at/gv/egiz/smcc/AbstractSMCCSTALTest.java
@@ -1,6 +1,5 @@
package at.gv.egiz.smcc;
-import at.gv.egiz.smcc.ccid.CCID;
import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
@@ -10,17 +9,18 @@ import javax.smartcardio.CardTerminal;
import org.junit.Assert;
import org.junit.Before;
+import org.junit.Ignore;
import org.junit.Test;
import at.gv.egiz.bku.gui.BKUGUIFacade;
import at.gv.egiz.bku.smccstal.AbstractSMCCSTAL;
import at.gv.egiz.bku.smccstal.SMCCSTALRequestHandler;
+import at.gv.egiz.smcc.ccid.CCID;
import at.gv.egiz.stal.ErrorResponse;
import at.gv.egiz.stal.InfoboxReadRequest;
import at.gv.egiz.stal.InfoboxReadResponse;
import at.gv.egiz.stal.STALRequest;
import at.gv.egiz.stal.STALResponse;
-import org.junit.Ignore;
public class AbstractSMCCSTALTest extends AbstractSMCCSTAL implements
SMCCSTALRequestHandler {
@@ -87,32 +87,11 @@ public class AbstractSMCCSTALTest extends AbstractSMCCSTAL implements
}
-
- @Override
- public List<PINSpec> getPINSpecs() {
- return new ArrayList<PINSpec>();
- }
-
- @Override
- public void verifyPIN(PINSpec pinSpec, PINProvider pinProvider) {
- }
-
- @Override
- public void changePIN(PINSpec pinSpec, ChangePINProvider pinProvider) {
- }
-
- @Override
- public void activatePIN(PINSpec pinSpec, PINProvider pinProvider) {
- }
-
- @Override
- public void unblockPIN(PINSpec pinSpec, PINProvider pukProvider) {
- }
-
- @Override
- public CCID getReader() {
- throw new UnsupportedOperationException("Not supported yet.");
- }
+ @Override
+ public CCID getReader() {
+ // TODO Auto-generated method stub
+ return null;
+ }
};
return false;