示例#1
0
 def test_not_a_string(self):
     string = 12345
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(string, converted)
示例#2
0
 def test_trailing_space(self):
     string = 'http://example.com  '
     expected = 'http://example.com'
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(expected, converted)
示例#3
0
 def test_space_between(self):
     string = 'http://example.com/space between url '
     expected = 'http://example.com/space between url'
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(expected, converted)
示例#4
0
def test_space_between():
    string = "http://example.com/space between url "
    expected = "http://example.com/space between url"
    converted = converters.remove_whitespace(string, {})
    assert expected == converted
示例#5
0
def test_not_a_string():
    string = 12345
    converted = converters.remove_whitespace(string, {})
    assert string == converted
示例#6
0
def test_trailing_space():
    string = "http://example.com  "
    expected = "http://example.com"
    converted = converters.remove_whitespace(string, {})
    assert expected == converted
示例#7
0
 def test_not_a_string(self):
     string = 12345
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(string, converted)
示例#8
0
 def test_space_between(self):
     string = 'http://example.com/space between url '
     expected = 'http://example.com/space between url'
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(expected, converted)
示例#9
0
 def test_trailing_space(self):
     string = 'http://example.com  '
     expected = 'http://example.com'
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(expected, converted)
 def test_leading_space(self):
     string = "  http://example.com"
     expected = "http://example.com"
     converted = converters.remove_whitespace(string, {})
     self.assertEqual(expected, converted)