mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-29 23:58:06 +01:00
4f3fc95d50
* Use @metamask/eslint-config@1.1.0 * Use eslint-plugin-mocha@6.2.2 * Mark root ESLint config as root * Update Mocha ESLint rules with shared ESLint config
31 lines
916 B
JavaScript
31 lines
916 B
JavaScript
import assert from 'assert'
|
|
import etherscanNetworkPrefix from '../../../ui/lib/etherscan-prefix-for-network'
|
|
|
|
describe('Etherscan Network Prefix', function () {
|
|
|
|
it('returns empy string as default value', function () {
|
|
assert.equal(etherscanNetworkPrefix(), '')
|
|
})
|
|
|
|
it('returns empty string as a prefix for networkId of 1', function () {
|
|
assert.equal(etherscanNetworkPrefix(1), '')
|
|
})
|
|
|
|
it('returns ropsten as prefix for networkId of 3', function () {
|
|
assert.equal(etherscanNetworkPrefix(3), 'ropsten.')
|
|
})
|
|
|
|
it('returns rinkeby as prefix for networkId of 4', function () {
|
|
assert.equal(etherscanNetworkPrefix(4), 'rinkeby.')
|
|
})
|
|
|
|
it('returs kovan as prefix for networkId of 42', function () {
|
|
assert.equal(etherscanNetworkPrefix(42), 'kovan.')
|
|
})
|
|
|
|
it('returs goerli as prefix for networkId of 5', function () {
|
|
assert.equal(etherscanNetworkPrefix(5), 'goerli.')
|
|
})
|
|
|
|
})
|