chiark / gitweb /
jjstest: lower: formatting of test cases and output
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 10 Jul 2021 10:47:29 +0000 (11:47 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 10 Jul 2021 10:48:50 +0000 (11:48 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
jstest/from-pieces
jstest/jst-lower.rs

index f5507288b77a6f96dfbc7a0657ff495f50457348..690494d8bbe112d8800dede74c3ee3eb4f82814d 100755 (executable)
@@ -20,8 +20,8 @@ my @pieces = map {
   [
    $p->{z},
    $p->{zg},
-   (sprintf "    sp!(\"%s\", %s, %s),%s\n",
-    $id,
+   (sprintf "    sp!(%7s, %s, %s),%s\n",
+    "\"$id\"",
     $p->{pinned} ? 'true' : 'false',
     $p->{moveable} eq 'IfWresting' ? 'No' : $p->{moveable},
     $p->{held} ? " // HELD $p->{held}" : '',
index 19982753903ffa3d8ea704bf2e775cf0a3458d72..74a5e7aa43b0037122efc3335420e7842faa8f84 100644 (file)
@@ -108,8 +108,8 @@ impl Test {
     let new = sorted(&|p: &PieceCollated| p.new_z);
     for (o, n) in izip!(&old, &new).rev() {
       let pr = |p: &PieceCollated| {
-        eprint!("    {} {}{}{} ",
-                p.id,
+        eprint!("    {:5} {}{}{} ",
+                p.id.to_string(),
                 if p.target  { "T" } else { "_" },
                 if p.bottom  { "B" } else { "_" },
                 if p.updated { "U" } else { "_" });