do it like this ``self.assertRaises(ValueError, s, resample, 'T', kind='period')``

and then do

``assert_series_equal(result, result2)``