def test_single(self): """ Split a single header with no parameters. """ self.assertThat( _splitHeaders(['foo']), Equals([('foo', {})]))
def test_params(self): """ Split header values containing parameters. """ self.assertThat( _splitHeaders(['foo,bar;quux=1']), Equals([('foo', {}), ('bar', {'quux': '1'})]))
def test_multiple(self): """ Split multiple headers with no parameters. """ self.assertThat( _splitHeaders(['foo', 'bar']), Equals([('foo', {}), ('bar', {})]))
def test_commas(self): """ Split a single header containing multiple values separated by commas with no parameters. """ self.assertThat( _splitHeaders(['foo,bar']), Equals([('foo', {}), ('bar', {})]))