typographic-currency
Advanced tools
Comparing version 1.1.1 to 1.1.2
{ | ||
"name": "typographic-currency", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "Use the correct symbol of currency", | ||
@@ -40,5 +40,5 @@ "main": "index.es5.js", | ||
"assert": "*", | ||
"babel-cli": "^6.2.0", | ||
"babel-core": "^6.2.1", | ||
"babel-preset-es2015": "^6.1.18", | ||
"babel-cli": "^6.24.1", | ||
"babel-core": "^6.24.1", | ||
"babel-preset-es2015": "^6.24.1", | ||
"coveralls": "*", | ||
@@ -45,0 +45,0 @@ "isparta": "^4.0.0", |
11
test.js
import { equal } from 'assert'; | ||
import typographicCurrency from './index'; | ||
it('should typographicCurrency', () => { | ||
it('should list of currency', () => { | ||
equal(typographicCurrency('102 AWG EUR INR KZT'), '102 ƒ € ₹ ₸'); | ||
equal(typographicCurrency('In my wallet KHR,KPW,KRW,LAK,LKR,MNT,MTL,MUR'), 'In my wallet ៛,₩,₩,₭,₨,₮,₤,₨'); | ||
}); | ||
it('should in sentence', () => { | ||
equal(typographicCurrency('My Tesla costs about 80usd'), 'My Tesla costs about 80$'); | ||
equal(typographicCurrency('BTC is not real'), 'Ƀ is not real'); | ||
}); | ||
it('not replace in words', () => { | ||
equal(typographicCurrency('Natural rubber'), 'Natural rubber'); | ||
// equal(typographicCurrency('I know php 7'), 'I know php 7'); TODO: https://github.com/talgautb/typographic-currency/issues/4 | ||
}); |
5040
39