def test_code_set_bad_value(self): r = Reply() with assert_raises(ValueError): r.code = 'asdf'
def test_esc_without_code(self): r = Reply() r.enhanced_status_code = '2.3.4' assert_equal(None, r.enhanced_status_code) r.code = '250' assert_equal('2.3.4', r.enhanced_status_code)
def test_code_set(self): r = Reply() r.code = None assert_equal(None, r.code) r.code = '100' assert_equal('100', r.code)
def test_esc_without_code(self): r = Reply() r.enhanced_status_code = '2.3.4' self.assertEqual(None, r.enhanced_status_code) r.code = '250' self.assertEqual('2.3.4', r.enhanced_status_code)
def test_code_set_bad_value(self): r = Reply() with self.assertRaises(ValueError): r.code = 'asdf'
def test_code_set(self): r = Reply() r.code = None self.assertEqual(None, r.code) r.code = '100' self.assertEqual('100', r.code)