From: Aaron Traas Date: Mon, 19 Jun 2017 17:09:15 +0000 (-0400) Subject: Save/resume fail test coverage -- test works in Docker now X-Git-Tag: 1.1~214 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=18a9be501ff8f0c57c5d540d0f5cd080c0438cd0;p=open-adventure.git Save/resume fail test coverage -- test works in Docker now --- diff --git a/tests/resumefail.chk b/tests/resumefail.chk new file mode 100644 index 0000000..27f8271 --- /dev/null +++ b/tests/resumefail.chk @@ -0,0 +1,33 @@ + +Welcome to Adventure!! Would you like instructions? + +> n + +You are standing at the end of a road before a small brick building. +Around you is a forest. A small stream flows out of the building and +down a gully. + +> seed 1240742801 +Seed set to 1240742801 + +You're in front of building. + +> resume + +To resume an earlier Adventure, you must abandon the current one. + +Is this acceptable? + +> y + +OK +Can't open file /badfilename, try again. + +You're in front of building. + + +You scored 32 out of a possible 430, using 1 turn. + +You are obviously a rank amateur. Better luck next time. + +To achieve the next higher rating, you need 14 more points. diff --git a/tests/resumefail.log b/tests/resumefail.log new file mode 100644 index 0000000..053b05f --- /dev/null +++ b/tests/resumefail.log @@ -0,0 +1,6 @@ +## Resume from invalid filename +n +seed 1240742801 +resume +y +/badfilename \ No newline at end of file diff --git a/tests/savefail.chk b/tests/savefail.chk new file mode 100644 index 0000000..7bce9d0 --- /dev/null +++ b/tests/savefail.chk @@ -0,0 +1,34 @@ + +Welcome to Adventure!! Would you like instructions? + +> n + +You are standing at the end of a road before a small brick building. +Around you is a forest. A small stream flows out of the building and +down a gully. + +> seed 1240742801 +Seed set to 1240742801 + +You're in front of building. + +> save + +I can suspend your Adventure for you so that you can resume later, but +it will cost you 5 points. + +Is this acceptable? + +> y + +OK +Can't open file /, try again. + +You're in front of building. + + +You scored 27 out of a possible 430, using 1 turn. + +You are obviously a rank amateur. Better luck next time. + +To achieve the next higher rating, you need 19 more points. diff --git a/tests/savefail.log b/tests/savefail.log new file mode 100644 index 0000000..f907d99 --- /dev/null +++ b/tests/savefail.log @@ -0,0 +1,6 @@ +## Save right after starting to invalid filename +n +seed 1240742801 +save +y +/ \ No newline at end of file