diff options
| author | Mike Naberezny | 2014-02-03 10:34:03 -0800 |
|---|---|---|
| committer | Mike McQuaid | 2014-02-03 19:33:34 +0000 |
| commit | f6311cb271c6d9cd49582fc2b767c5614815cfd6 (patch) | |
| tree | 8a27e81b7b81063844b0afc941c866bd10df231d /Library/Formula | |
| parent | 91c60b9b5ea7f53d013997a13effbac5e9292d86 (diff) | |
| download | homebrew-f6311cb271c6d9cd49582fc2b767c5614815cfd6.tar.bz2 | |
acme: improve test by assembling a small file
Closes #26385.
Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/acme.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Library/Formula/acme.rb b/Library/Formula/acme.rb index d98494887..07ee7a131 100644 --- a/Library/Formula/acme.rb +++ b/Library/Formula/acme.rb @@ -13,6 +13,15 @@ class Acme < Formula end test do - system bin/'acme', '-V' + path = testpath/"a.asm" + path.write <<-EOS + !to "a.out", cbm + * = $c000 + jmp $fce2 + EOS + + system bin/"acme", path + code = File.open(testpath/"a.out", "rb") { |f| f.read.unpack("C*") } + assert_equal [0x00, 0xc0, 0x4c, 0xe2, 0xfc], code end end |
