示例#1
0
    def test_camelcase_sentance(self):

        self.assertEqual('helloWorld', camelCase.camelcase('Hello World'))
        self.assertEqual('minnesotaVikings',
                         camelCase.camelcase('   MInnesota    vIKINGS   '))
        self.assertEqual('', camelCase.camelcase(''))
        self.assertEqual('mVP', camelCase.camelcase(' M v  p'))
        self.assertEqual('!@#$%', camelCase.camelcase('   ! @  # $    %   '))
示例#2
0
    def test_camelCase_sentence(self):

        self.assertEqual('helloWorld', camelCase.camelcase('Hello World'))
        self.assertEqual('', camelCase.camelcase(''))
        self.assertEqual('helloWorld',
                         camelCase.camelcase('    HELLO    WORLD   '))
        self.assertEqual('helloWorld1', camelCase.camelcase('Hello World 1'))
        self.assertEqual('helloWorld', camelCase.camelcase('Hello, worlD'))
        self.assertEqual('hello', camelCase.camelcase('Hello'))
        self.assertEqual('😀😁😂🤣😃😄😅😆😉', camelCase.camelcase('😀 😁 😂 🤣 😃 😄 😅 😆 😉'))
 def test_camelcase_sentance(self):
     self.assertEqual('helloWorld', camelCase.camelcase('Hello World'))
     self.assertEqual('myNameIsJosh',
                      camelCase.camelcase('My name is josh'))
 def test_camelcase_with_new_lines(self):
     self.assertEqual('helloWorldHelloWorld',
                      camelCase.camelcase('Hello World \n Hello World'))
 def test_camelcase_more_than_one_space(self):
     self.assertEqual('helloWorld', camelCase.camelcase('Hello    World'))
 def test_camelcase_string_with_numbers(self):
     self.assertEqual('helloWorld13',
                      camelCase.camelcase('Hello World 1 3'))
 def test_empty_string(self):
     self.assertEqual('', camelCase.camelcase(''))
 def test_strings_with_whitespace_at_end(self):
     self.assertEqual('helloWorld', camelCase.camelcase('Hello World  '))
 def test_camelcase_one_word(self):
     self.assertEqual('hello', camelCase.camelcase('HELLO'))
示例#10
0
 def test_camelcase_sentence(self):
     self.assertEqual('helloWorld', camelCase.camelcase('Hello World'))
示例#11
0
 def test_camelcase_sentence(self):
     user_sentence = 'Hello World'
     expected_result = 'helloWorld'
     self.assertEqual(expected_result, camelCase.camelcase(user_sentence))
示例#12
0
    def test_camelcase_sentence(self):

        self.assertEqual("helloWorld", camelCase.camelcase("Hello World"))
示例#13
0
 def test_space(self):    
     
     self.assertEqual("", camelCase.camelcase(""))
示例#14
0
    def test_if_numbers_work(self):
        bad_string = 'lets test 3 numbers and see 123'

        result = camelCase.camelcase(bad_string)

        self.assertTrue(result)