Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
E
Enigma
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dennis Eisold
Enigma
Commits
a76b4bff
Commit
a76b4bff
authored
5 years ago
by
Dennis Eisold
Browse files
Options
Downloads
Patches
Plain Diff
Unit Test für Reflektor und Steckbrett
parent
bb984ff2
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/test/java/Enigma/model/ReflektorTest.java
+33
-0
33 additions, 0 deletions
src/test/java/Enigma/model/ReflektorTest.java
src/test/java/Enigma/model/SteckbrettTest.java
+36
-0
36 additions, 0 deletions
src/test/java/Enigma/model/SteckbrettTest.java
with
69 additions
and
0 deletions
src/test/java/Enigma/model/ReflektorTest.java
0 → 100644
+
33
−
0
View file @
a76b4bff
package
Enigma.model
;
import
org.junit.Assert
;
import
org.junit.Test
;
public
class
ReflektorTest
{
@Test
public
void
codiere
()
{
/*
Reflektor r = new Reflektor();
Assert.assertEquals('E', r.codiere('A'));
Assert.assertEquals('Z', r.codiere('D'));
Assert.assertEquals('X', r.codiere('H'));
Assert.assertEquals('O', r.codiere('Q'));
Assert.assertEquals('I', r.codiere('V'));
//Assert.assertNull(null, r.codiere(null));
*/
}
@Test
public
void
codiere2
()
{
/*
Reflektor r = new Reflektor();
Assert.assertEquals('A', r.codiere('E'));
Assert.assertEquals('D', r.codiere('Z'));
Assert.assertEquals('H', r.codiere('X'));
Assert.assertEquals('Q', r.codiere('O'));
Assert.assertEquals('V', r.codiere('I'));
*/
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
src/test/java/Enigma/model/SteckbrettTest.java
0 → 100644
+
36
−
0
View file @
a76b4bff
package
Enigma.model
;
import
org.junit.Assert
;
import
org.junit.Test
;
import
static
org
.
junit
.
Assert
.*;
public
class
SteckbrettTest
{
@Test
public
void
setzeVertauschung
()
{
/*Steckbrett sb = new Steckbrett();
sb.setzeVertauschung('A', 'G');
sb.setzeVertauschung('C', 'H');
Assert.assertEquals('H', sb.codiere('C'));
Assert.assertEquals('G', sb.codiere('A'));*/
}
@Test
public
void
codiere
()
{
/*Steckbrett sb = new Steckbrett();
sb.setzeVertauschung('A', 'G');
sb.setzeVertauschung('C', 'H');
Assert.assertEquals('H', sb.codiere('C'));
Assert.assertEquals('G', sb.codiere('A'));*/
}
@Test
public
void
codiere2
()
{
/*Steckbrett sb = new Steckbrett();
sb.setzeVertauschung('A', 'G');
sb.setzeVertauschung('C', 'H');
Assert.assertEquals('C', sb.codiere2('H'));
Assert.assertEquals('A', sb.codiere2('G'));*/
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment