Commit c7fc3340 authored by Hans-Peter Deifel's avatar Hans-Peter Deifel 🐢
Browse files

minimize tests: Require newline before EOF

A final newline is automatically inserted by many traditional unix tools and
editors, which makes editing .mini files rather hard with e.g

 - vim, emacs,
 - `copar minimize foo.input > foo.mini`.

All of the above insert a trailing newline automatically.
parent e00fce23
{f, n}xX^{a, b}
s0_q1_q2: (n, {a: s0_q1_q2, b: s1_q3})
s1_q3: (f, {a: s0_q1_q2, b: s0_q1_q2})
\ No newline at end of file
s1_q3: (f, {a: s0_q1_q2, b: s0_q1_q2})
......@@ -13,4 +13,4 @@ s09_d5: {(s10_d6, s02_b2_b3_bot)}
s10_d6: {(s11_d7, s02_b2_b3_bot)}
s11_d7: {(s12_d8, s02_b2_b3_bot)}
s12_d8: {(s13_d9, s02_b2_b3_bot)}
s13_d9: {(s05_d10, s02_b2_b3_bot)}
\ No newline at end of file
s13_d9: {(s05_d10, s02_b2_b3_bot)}
......@@ -3,4 +3,4 @@
@init s0_q1_q2
s0_q1_q2: (n, {a: s0_q1_q2, b: s1_q3})
s1_q3: (f, {a: s0_q1_q2, b: s0_q1_q2})
\ No newline at end of file
s1_q3: (f, {a: s0_q1_q2, b: s0_q1_q2})
......@@ -2,4 +2,4 @@ R^X
@init s1_zero
s1_zero: {}
\ No newline at end of file
s1_zero: {}
......@@ -12,4 +12,4 @@ s09_d5: {(s10_d6, s02_b2_b3_bot)}
s10_d6: {(s11_d7, s02_b2_b3_bot)}
s11_d7: {(s12_d8, s02_b2_b3_bot)}
s12_d8: {(s13_d9, s02_b2_b3_bot)}
s13_d9: {(s05_d10, s02_b2_b3_bot)}
\ No newline at end of file
s13_d9: {(s05_d10, s02_b2_b3_bot)}
{circled, normal} x Ƥ(ƤX)
a1: (normal, {{a1}})
\ No newline at end of file
a1: (normal, {{a1}})
R^(X)^{a, b}
s0_s1: {a: {s0_s1: 0.3}, b: {s0_s1: 0.8}}
\ No newline at end of file
s0_s1: {a: {s0_s1: 0.3}, b: {s0_s1: 0.8}}
......@@ -95,9 +95,10 @@ testFileMinimize mini =
let
(enc', symTab') = minimize f enc symTab part
return (LT.unpack . Build.toLazyText $ Build.fromText (printParseableFunctor f)
<> "\n\n"
<> printEncoding enc' symTab' (sortTable f))
return (LT.unpack . Build.toLazyText $ Build.fromText (printParseableFunctor f)
<> "\n\n"
<> printEncoding enc' symTab' (sortTable f)
<> "\n")
testFileMinimizeIdentity :: FilePath -> Spec
testFileMinimizeIdentity file =
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment