require 'test/unit' require 'kenyacodes' class KenyacodesTest < Test::Unit::TestCase def test_postoffice mycodes = Kenyacodes::Postcodes.new assert_equal 'Kerugoya',mycodes.postoffice('10300') end def test_postcode mycodes = Kenyacodes::Postcodes.new assert_equal '10300', mycodes.postcode('Kerugoya') end def test_othercodes provinces = Kenyacodes::Total_provinces kenyacode = Kenyacodes::Kenya_international_code assert_equal 254, kenyacode assert_equal 8, provinces end end