def test_rsub_old_empty_new_str(): assert rsub("abcdef", "", "123") == "abcdef123"
def test_rsub_old_empty_new_empty(): assert rsub("abcdef", "") == "abcdef"
def test_rsub_old_str_new_empty(): assert rsub("abcdef", "def") == "abc"
def test_rsub_old_str_new_str(): assert rsub("abcdef", "def", "123") == "abc123"
def test_rsub_no_match(): assert rsub("abcdef", "xyz") == "abcdef"