mirror of
https://github.com/soxoj/maigret.git
synced 2026-05-06 22:19:01 +00:00
16 lines
350 B
Python
16 lines
350 B
Python
"""Maigret utils test functions"""
|
|
from maigret.utils import CaseConverter
|
|
|
|
|
|
def test_case_convert_camel_to_snake():
|
|
a = 'SnakeCasedString'
|
|
b = CaseConverter.camel_to_snake(a)
|
|
|
|
assert b == 'snake_cased_string'
|
|
|
|
def test_case_convert_snake_to_camel():
|
|
a = 'camel_cased_string'
|
|
b = CaseConverter.snake_to_camel(a)
|
|
|
|
assert b == 'camelCasedString'
|