Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Eric Duminil
RegionChooser
Commits
e43835c8
Commit
e43835c8
authored
2 years ago
by
Eric Duminil
Browse files
Options
Download
Email Patches
Plain Diff
basic, broken tests.
parent
5e5c6a52
master
develop
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/test/java/eu/simstadt/regionchooser/RegionChooserCommandLineInterfaceTest.java
+28
-0
.../regionchooser/RegionChooserCommandLineInterfaceTest.java
with
28 additions
and
0 deletions
+28
-0
src/test/java/eu/simstadt/regionchooser/RegionChooserCommandLineInterfaceTest.java
0 → 100644
+
28
-
0
View file @
e43835c8
package
eu.simstadt.regionchooser
;
import
static
org
.
junit
.
jupiter
.
api
.
Assertions
.
assertEquals
;
import
java.io.PrintWriter
;
import
java.io.StringWriter
;
import
org.junit.jupiter.api.Test
;
import
picocli.CommandLine
;
class
RegionChooserCommandLineInterfaceTest
{
@Test
void
testCLIWithoutArgument
()
{
RegionChooserCommandLineInterface
app
=
new
RegionChooserCommandLineInterface
();
CommandLine
cmd
=
new
CommandLine
(
app
);
StringWriter
sw
=
new
StringWriter
();
cmd
.
setOut
(
new
PrintWriter
(
sw
));
// black box testing
int
exitCode
=
cmd
.
execute
(
"--input=input.gml"
,
"--output=output.gml"
,
"--wkt=input.wkt"
);
assertEquals
(
0
,
exitCode
);
assertEquals
(
"Your output is abc..."
,
sw
.
toString
());
}
}
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets