import test from 'ava';
import decamelize from '.';

test('decamelize', t => {
	t.is(decamelize(''), '');
	t.is(decamelize('unicornsAndRainbows'), 'unicorns_and_rainbows');
	t.is(decamelize('UNICORNS AND RAINBOWS'), 'unicorns and rainbows');
	t.is(decamelize('unicorns-and-rainbows'), 'unicorns-and-rainbows');
	t.is(decamelize('thisIsATest'), 'this_is_a_test');
	t.is(decamelize('thisIsATest', ' '), 'this is a test');
	t.is(decamelize('thisIsATest', ''), 'thisisatest');
	t.is(decamelize('unicornRainbow', '|'), 'unicorn|rainbow');
	t.is(decamelize('myURLString', '_'), 'my_url_string');
	t.is(decamelize('URLString', '_'), 'url_string');
	t.is(decamelize('StringURL', '_'), 'string_url');
	t.is(decamelize('thisHasSpecialCharactersLikeČandŠ', ' '), 'this has special characters like čand š');
});

@@ -523,24 +523,165 @@
 %7Crainbow');%0A
+%09t.is(decamelize('thisHasSpecialCharactersLike%C4%8Cand%C5%A0', ' '), 'this has special characters like %C4%8Dand %C5%A1');%0A%7D);%0A%0Atest('handles acronyms', t =%3E %7B%0A
 %09t.is(decame
@@ -694,29 +694,24 @@
 myURLString'
-, '_'
 ), 'my_url_s
@@ -747,21 +747,16 @@
 LString'
-, '_'
 ), 'url_
@@ -797,13 +797,8 @@
 URL'
-, '_'
 ), '
@@ -834,89 +834,38 @@
 e('t
-hisHasSpecialCharactersLike%C4%8Cand%C5%A0', ' '), 'this has special characters like %C4%8Dand %C5%A1
+estGUILabel'), 'test_gui_label
 ');%0A

Add test for #20