aboutsummaryrefslogtreecommitdiff
path: root/src/cz/crcs/ectester/reader/test/CommandTestable.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/cz/crcs/ectester/reader/test/CommandTestable.java')
-rw-r--r--src/cz/crcs/ectester/reader/test/CommandTestable.java44
1 files changed, 0 insertions, 44 deletions
diff --git a/src/cz/crcs/ectester/reader/test/CommandTestable.java b/src/cz/crcs/ectester/reader/test/CommandTestable.java
deleted file mode 100644
index f670534..0000000
--- a/src/cz/crcs/ectester/reader/test/CommandTestable.java
+++ /dev/null
@@ -1,44 +0,0 @@
-package cz.crcs.ectester.reader.test;
-
-import cz.crcs.ectester.common.test.BaseTestable;
-import cz.crcs.ectester.common.test.TestException;
-import cz.crcs.ectester.reader.command.Command;
-import cz.crcs.ectester.reader.response.Response;
-
-import javax.smartcardio.CardException;
-
-/**
- * @author Jan Jancar johny@neuromancer.sk
- */
-public class CommandTestable extends BaseTestable {
- private Command command;
- private Response response;
-
- public CommandTestable(Command command) {
- this.command = command;
- }
-
- public Command getCommand() {
- return command;
- }
-
- public Response getResponse() {
- return response;
- }
-
- @Override
- public void run() {
- try {
- response = command.send();
- } catch (CardException e) {
- throw new TestException(e);
- }
-
- hasRun = true;
- if (response.error()) {
- error = true;
- } else if (response.successful()) {
- ok = true;
- }
- }
-}