Skip to content

Commit 91e9a33

Browse files
committed
lightly refactor hof tests
1 parent 37876fd commit 91e9a33

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/hof_test.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ describe('HOF #1', function() {
1414
catch(e) {
1515
console.log(e)
1616
}
17-
it('should use Array.map', function() {
18-
expect(hof.match(/map/g).length).to.equal(2)
19-
})
20-
it('should be an array', function() {
17+
it('peopleNames should be an array', function() {
2118
expect(peopleNames).to.be.an('array')
2219
})
23-
it('should contain the names of each person in the people array', function() {
20+
it('.map should be called on `people`', function() {
21+
expect(hof.match(/people\.map/g).length).to.be.at.least(1)
22+
})
23+
it('peopleNames should contain the names of each person in the people array', function() {
2424
let names = ["Layla", "Keanu", "Jasmine"]
2525
expect(
2626
peopleNames.every((name, index) => {

0 commit comments

Comments
 (0)