From dac1155f718c183e3842651ce32ab929a87abf68 Mon Sep 17 00:00:00 2001 From: Steve Smith Date: Wed, 15 Mar 2017 13:54:47 +0000 Subject: [PATCH] Don't check message for freeze test Ruby 1.8.7 doesn't cope well checking the message. Uses RuntimeError, TypeError as 1.8.7 needs TypeError. --- test/language_list_test.rb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/test/language_list_test.rb b/test/language_list_test.rb index 38f11df..9cbdc62 100755 --- a/test/language_list_test.rb +++ b/test/language_list_test.rb @@ -139,39 +139,39 @@ def test_common_name_when_not_present end def test_cannot_change_constants - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::ALL_LANGUAGES[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::ISO_639_1[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::LIVING_LANGUAGES[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::COMMON_LANGUAGES[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::BY_NAME[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::BY_ISO_639_1[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::BY_ISO_639_3[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::BY_ISO_639_2T[0] = nil end - assert_raises RuntimeError, /frozen Array/i do + assert_raises RuntimeError, TypeError do LanguageList::BY_ISO_639_2B[0] = nil end end