This repository has been archived by the owner on Mar 12, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add --maxtime and increase coverage #1
- Cover all missing cases for the resources. - Cover the web server app. - Cover Id.compare.
- Loading branch information
Showing
6 changed files
with
110 additions
and
10 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
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
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
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
13 changes: 13 additions & 0 deletions
13
src/test/scala/de/retest/guistatemachine/WebServerSpec.scala
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 @@ | ||
package de.retest.guistatemachine | ||
|
||
import org.scalatest.WordSpec | ||
import org.scalatest.Matchers | ||
|
||
class WebServerSpec extends WordSpec with Matchers { | ||
|
||
"The web server" should { | ||
"start and end successfully" in { | ||
WebServer.main(Array("--maxtime=1000")) | ||
} | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
src/test/scala/de/retest/guistatemachine/model/IdSpec.scala
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,17 @@ | ||
package de.retest.guistatemachine.model | ||
|
||
import org.scalatest.WordSpec | ||
import org.scalatest.Matchers | ||
|
||
class IdSpec extends WordSpec with Matchers { | ||
|
||
"Id" should { | ||
"compare" in { | ||
val id0 = Id(0) | ||
val id1 = Id(1) | ||
id0.compare(id0) shouldEqual 0 | ||
id0.compare(id1) shouldEqual -1 | ||
id1.compare(id0) shouldEqual 1 | ||
} | ||
} | ||
} |