-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
18 changed files
with
59,740 additions
and
57,801 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
const test = require('ava').default; | ||
const zipCount = require('../zipCount'); | ||
const zipArray = require('../array'); | ||
const test = require('ava').default | ||
const zipCount = require('../zipCount') | ||
const zipArray = require('../array') | ||
|
||
test('exports the correct number of zips', t => { | ||
t.is(zipArray.length, zipCount); | ||
}); | ||
t.is(zipArray.length, zipCount) | ||
}) | ||
|
||
test('exports the expected format', t => { | ||
t.true(Array.isArray(zipArray)); | ||
t.true(Array.isArray(zipArray)) | ||
|
||
t.is(typeof zipArray[0], 'object'); | ||
t.is(typeof zipArray[0], 'object') | ||
|
||
t.truthy(zipArray[0].latitude); | ||
t.truthy(zipArray[0].longitude); | ||
t.truthy(zipArray[0].zipCode); | ||
}); | ||
t.truthy(zipArray[0].latitude) | ||
t.truthy(zipArray[0].longitude) | ||
t.truthy(zipArray[0].zipCode) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
const test = require('ava').default; | ||
const zipCount = require('../zipCount'); | ||
const zipKeyValue = require('../key-value'); | ||
const test = require('ava').default | ||
const zipCount = require('../zipCount') | ||
const zipKeyValue = require('../key-value') | ||
|
||
test('exports the correct number of zips', t => { | ||
t.is(zipKeyValue.length, zipCount); | ||
}); | ||
t.is(zipKeyValue.length, zipCount) | ||
}) | ||
|
||
test('exports the expected format', t => { | ||
t.true(Array.isArray(zipKeyValue)); | ||
t.true(Array.isArray(zipKeyValue)) | ||
|
||
const [zipCode, location] = zipKeyValue[0]; | ||
const [zipCode, location] = zipKeyValue[0] | ||
|
||
t.truthy(zipCode); | ||
t.truthy(location.latitude); | ||
t.truthy(location.longitude); | ||
}); | ||
t.truthy(zipCode) | ||
t.truthy(location.latitude) | ||
t.truthy(location.longitude) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
const test = require('ava').default; | ||
const zipCount = require('../zipCount'); | ||
const zipMap = require('../map'); | ||
const test = require('ava').default | ||
const zipCount = require('../zipCount') | ||
const zipMap = require('../map') | ||
|
||
test('exports the correct number of zips', t => { | ||
t.is(zipMap.size, zipCount); | ||
}); | ||
t.is(zipMap.size, zipCount) | ||
}) | ||
|
||
test('exports the expected format', t => { | ||
t.true(zipMap instanceof Map); | ||
t.true(zipMap instanceof Map) | ||
|
||
const testZip = zipMap.get('38873'); | ||
const testZip = zipMap.get('38873') | ||
|
||
t.truthy(testZip.latitude); | ||
t.truthy(testZip.longitude); | ||
}); | ||
t.truthy(testZip.latitude) | ||
t.truthy(testZip.longitude) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
const test = require('ava').default; | ||
const zipCount = require('../zipCount'); | ||
const usZips = require('../object'); | ||
const test = require('ava').default | ||
const zipCount = require('../zipCount') | ||
const usZips = require('../object') | ||
|
||
test('exports the correct number of zips', t => { | ||
const numberExported = Object.keys(usZips).length; | ||
t.is(numberExported, zipCount); | ||
}); | ||
const numberExported = Object.keys(usZips).length | ||
t.is(numberExported, zipCount) | ||
}) | ||
|
||
test('exports the expected format', t => { | ||
t.is(typeof usZips, 'object'); | ||
t.is(typeof usZips, 'object') | ||
|
||
const testZip = usZips['37214']; | ||
const testZip = usZips['37214'] | ||
|
||
t.is(typeof testZip, 'object'); | ||
t.truthy(testZip.latitude); | ||
t.truthy(testZip.longitude); | ||
}); | ||
t.is(typeof testZip, 'object') | ||
t.truthy(testZip.latitude) | ||
t.truthy(testZip.longitude) | ||
}) |
Oops, something went wrong.