1234567891011121314151617 |
- Describe(camel_to_snake)
- {
- // camelCase to snake_case tests
- It(test1){Assert::That(toSnakeCase("edabit"), Equals("edabit"));}
- It(test2){Assert::That(toSnakeCase("helloEdabit"), Equals("hello_edabit"));}
- It(test3){Assert::That(toSnakeCase("isModalOpen"), Equals("is_modal_open"));}
- It(test4){Assert::That(toSnakeCase("getBackgroundColor"), Equals("get_background_color"));}
- It(test5){Assert::That(toSnakeCase("isLoading"), Equals("is_loading"));}
- It(test6){Assert::That(toSnakeCase("x"), Equals("x"));}
- // snake_case to camelCase tests
- It(test7){Assert::That(toCamelCase("edabit"), Equals("edabit"));}
- It(test8){Assert::That(toCamelCase("hello_edabit"), Equals("helloEdabit"));}
- It(test9){Assert::That(toCamelCase("is_modal_open"), Equals("isModalOpen"));}
- It(test10){Assert::That(toCamelCase("get_background_color"), Equals("getBackgroundColor"));}
- It(test11){Assert::That(toCamelCase("is_loading"), Equals("isLoading"));}
- It(test12){Assert::That(toCamelCase("x"), Equals("x"));}
- };
|