From 9e0eca64e8d66cb37ba9a764ae17205bd74fdba7 Mon Sep 17 00:00:00 2001 From: Deepi Garg <48362243+deepigarg@users.noreply.github.com> Date: Sat, 28 Mar 2020 22:47:04 +0530 Subject: [PATCH] Update test_word.rb --- test/parfait/test_word.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/parfait/test_word.rb b/test/parfait/test_word.rb index 9289d4de..9e1c844f 100644 --- a/test/parfait/test_word.rb +++ b/test/parfait/test_word.rb @@ -26,15 +26,19 @@ module Parfait @word.set_char(1 , 32) end end - def test_insert + def test_insert_1 a = Parfait.new_word("abc") b = Parfait.new_word("d") ans = Parfait.new_word("abcd") assert_equal ans, a.insert(-1,b) + end + def test_insert_2 a1 = Parfait.new_word("what name") b1 = Parfait.new_word("is your ") ans = Parfait.new_word("what is your name") assert_equal ans, a1.insert(5, b1) + end + def test_insert_3 a2 = Parfait.new_word("life") b2 = Parfait.new_word("sad ") ans = Parfait.new_word("sad life")