aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/helpers/tests/common.util.test.js
diff options
context:
space:
mode:
authorDan Finlay <542863+danfinlay@users.noreply.github.com>2018-10-06 01:19:43 +0800
committerGitHub <noreply@github.com>2018-10-06 01:19:43 +0800
commit182970c3181fa50c6e6767b0810d98f4cd6380e0 (patch)
tree7fc1bdc9881d55169fee4139321b30f066fdec05 /ui/app/helpers/tests/common.util.test.js
parentbf9fe1498bdac5793b47b61eb391c5466d5c1e90 (diff)
parent50d91f998d0dc228c1d5dac7966df89d6c3fe6c4 (diff)
downloadtangerine-wallet-browser-182970c3181fa50c6e6767b0810d98f4cd6380e0.tar.gz
tangerine-wallet-browser-182970c3181fa50c6e6767b0810d98f4cd6380e0.tar.zst
tangerine-wallet-browser-182970c3181fa50c6e6767b0810d98f4cd6380e0.zip
Merge pull request #5432 from alextsg/i5362-fix-translate
Translate method names in the transaction list only when applicable
Diffstat (limited to 'ui/app/helpers/tests/common.util.test.js')
-rw-r--r--ui/app/helpers/tests/common.util.test.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/ui/app/helpers/tests/common.util.test.js b/ui/app/helpers/tests/common.util.test.js
new file mode 100644
index 000000000..891e19ef5
--- /dev/null
+++ b/ui/app/helpers/tests/common.util.test.js
@@ -0,0 +1,23 @@
+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: '',
+ expected: '',
+ },
+ {
+ test: 'thisIsATest',
+ expected: 'This Is A Test',
+ },
+ ]
+
+ tests.forEach(({ test, expected }) => {
+ assert.equal(utils.camelCaseToCapitalize(test), expected)
+ })
+ })
+ })
+})