14 lines
356 B
Ruby
14 lines
356 B
Ruby
require_relative "lib.rb"
|
|
require "test/unit"
|
|
|
|
class TestAntinodeCounter < Test::Unit::TestCase
|
|
def test_part_1
|
|
input = File.readlines("test.txt", chomp: true)
|
|
assert_equal(14, count_antinodes(input, true))
|
|
end
|
|
|
|
def test_part_2
|
|
input = File.readlines("test.txt", chomp: true)
|
|
assert_equal(34, count_antinodes(input, false))
|
|
end
|
|
end
|