Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove overlapping test #1219

Merged
merged 1 commit into from
Sep 12, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 1 addition & 19 deletions test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ test('logos path names should not contain space', function (t) {
t.end()
})

test('symbols should be six or less characters', function (t) {
test('symbols should be eleven or less characters', function (t) {
Object.keys(contractMap).forEach(address => {
const contract = contractMap[address]
const symbol = contract.symbol
Expand All @@ -88,21 +88,3 @@ test('only permitted fields should be used', function (t) {

t.end()
})

test('symbols should not overlap', function (t) {
const symbols = Object.values(contractMap).map(contract => contract.symbol)
const symbolsCheck = new Map()
let duplicateSymbol

symbols.forEach(symbol => {
if (symbolsCheck.has(symbol) && symbol !== undefined) {
duplicateSymbol = symbol
return
}
symbolsCheck.set(symbol, true)
})

const msg = duplicateSymbol ? `found overlapping symbol ${duplicateSymbol}` : 'symbols should not overlap'
t.notOk(duplicateSymbol, msg)
t.end()
})
Loading