ats2-postiats: use Pathname.write
This commit is contained in:
parent
7109e30c83
commit
c5c764036c
1 changed files with 4 additions and 6 deletions
|
@ -26,12 +26,10 @@ class Ats2Postiats < Formula
|
|||
end
|
||||
|
||||
test do
|
||||
File.open("hello.dats", "w") do |f|
|
||||
f.write <<-EOF.undent
|
||||
val _ = print ("Hello, world!\n")
|
||||
implement main0 () = ()
|
||||
EOF
|
||||
end
|
||||
(testpath/"hello.dats").write <<-EOS.undent
|
||||
val _ = print ("Hello, world!\n")
|
||||
implement main0 () = ()
|
||||
EOS
|
||||
system "#{bin}/patscc hello.dats -o hello"
|
||||
IO.popen("./hello", "r") do |pipe|
|
||||
assert_match "Hello, world!", pipe.read
|
||||
|
|
Loading…
Reference in a new issue