From: Aaron Traas Date: Sun, 2 Jul 2017 05:36:28 +0000 (-0400) Subject: Fixed -r option. Added test to make sure it doesn't break later. X-Git-Tag: takebird~125 X-Git-Url: https://jxself.org/git/?p=open-adventure.git;a=commitdiff_plain;h=be115e95678fd352c1a6ad5862c8d9b4fe56ddaf Fixed -r option. Added test to make sure it doesn't break later. --- diff --git a/main.c b/main.c index 2d207d8..9d466b4 100644 --- a/main.c +++ b/main.c @@ -61,7 +61,7 @@ int main(int argc, char *argv[]) /* Options. */ #ifndef ADVENT_NOSAVE - const char* opts = "l:or"; + const char* opts = "l:or:"; const char* usage = "Usage: %s [-l logfilename] [-o] [-r restorefilename]\n"; #else const char* opts = "l:o"; diff --git a/tests/saveresumeopt.chk b/tests/saveresumeopt.chk new file mode 100644 index 0000000..bc08d9b --- /dev/null +++ b/tests/saveresumeopt.chk @@ -0,0 +1,9 @@ + +You're in front of building. + + +You scored 27 out of a possible 430, using 2 turns. + +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/saveresumeopt.log b/tests/saveresumeopt.log new file mode 100644 index 0000000..af159ff --- /dev/null +++ b/tests/saveresumeopt.log @@ -0,0 +1,2 @@ +## Simple quit +#options: -r saveresume.adv