aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/helpers/utils/common.util.test.js
diff options
context:
space:
mode:
authorkumavis <aaron@kumavis.me>2019-03-29 11:54:12 +0800
committerkumavis <aaron@kumavis.me>2019-03-29 11:54:12 +0800
commit781a39c039500fcfe8fce3c3d75081ff781c4cf1 (patch)
tree5f7ba6db12b471ddd82e6be1d6e7dde0560d2cfd /ui/app/helpers/utils/common.util.test.js
parent07c974525859eba81471ec7591821ea010addf5a (diff)
parent649a1d483a574dcff902708f95b37329a02709a8 (diff)
downloadtangerine-wallet-browser-781a39c039500fcfe8fce3c3d75081ff781c4cf1.tar.gz
tangerine-wallet-browser-781a39c039500fcfe8fce3c3d75081ff781c4cf1.tar.zst
tangerine-wallet-browser-781a39c039500fcfe8fce3c3d75081ff781c4cf1.zip
Merge branch 'develop' into clearNotices
Diffstat (limited to 'ui/app/helpers/utils/common.util.test.js')
-rw-r--r--ui/app/helpers/utils/common.util.test.js27
1 files changed, 27 insertions, 0 deletions
diff --git a/ui/app/helpers/utils/common.util.test.js b/ui/app/helpers/utils/common.util.test.js
new file mode 100644
index 000000000..6259f4a89
--- /dev/null
+++ b/ui/app/helpers/utils/common.util.test.js
@@ -0,0 +1,27 @@
+import * as utils from './common.util'
+import assert from 'assert'
+
+describe('Common utils', () => {
+ describe('camelCaseToCapitalize', () => {
+ it('should return a capitalized string from a camel-cased string', () => {
+ const tests = [
+ {
+ test: undefined,
+ expected: '',
+ },
+ {
+ test: '',
+ expected: '',
+ },
+ {
+ test: 'thisIsATest',
+ expected: 'This Is A Test',
+ },
+ ]
+
+ tests.forEach(({ test, expected }) => {
+ assert.equal(utils.camelCaseToCapitalize(test), expected)
+ })
+ })
+ })
+})