about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-05-12 08:43:58 -0700
committerKartik K. Agaram <vc@akkartik.com>2015-05-12 08:46:53 -0700
commit66083e54a0a122e0b9f396ee32ee632065ecbb66 (patch)
tree36c2536f17302efd5e2364dbcdcc87e4029a9cfb
parent9131db6eda3d4034eae39a230b4044a2283f3310 (diff)
downloadmu-66083e54a0a122e0b9f396ee32ee632065ecbb66.tar.gz
1353
-rw-r--r--072scenario_screen.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/072scenario_screen.cc b/072scenario_screen.cc
index 18121424..2e563b82 100644
--- a/072scenario_screen.cc
+++ b/072scenario_screen.cc
@@ -121,7 +121,10 @@ void check_screen(const string& contents) {
     if ((!Memory[screen_data_start+i] && !isspace(expected_contents.at(i)))  // uninitialized memory => spaces
         || (Memory[screen_data_start+i] && Memory[screen_data_start+i] != expected_contents.at(i))) {
 //?       cerr << "CCC " << Trace_stream << " " << Hide_warnings << '\n'; //? 1
-      raise << "expected screen location (" << i/screen_width << ", " << i%screen_width << ") to contain '" << expected_contents.at(i) << "' instead of '" << static_cast<char>(Memory[screen_data_start+i]) << "'\n";
+      if (Current_scenario)
+        raise << "\nF - " << Current_scenario->name << ": expected screen location (" << i/screen_width << ", " << i%screen_width << ") to contain '" << expected_contents.at(i) << "' instead of '" << static_cast<char>(Memory[screen_data_start+i]) << "'\n";
+      else
+        raise << "expected screen location (" << i/screen_width << ", " << i%screen_width << ") to contain '" << expected_contents.at(i) << "' instead of '" << static_cast<char>(Memory[screen_data_start+i]) << "'\n";
       Passed = false;
       return;
     }