Skip to content

Commit

Permalink
Fixed shadowing name authors to authors-set.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jani Rahkola committed Oct 22, 2012
1 parent a570ec5 commit c6d2de3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/structured_data_test.clj
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
dick {:name "Philip K. Dick", :birth-year 1928, :death-year 1982}
zelazny {:name "Roger Zelazny", :birth-year 1937, :death-year 1995}

authors #{china, felleisen, octavia, friedman}
authors-set #{china, felleisen, octavia, friedman}

cities {:title "The City and the City" :authors #{china}}
wild-seed {:title "Wild Seed", :authors #{octavia}}
Expand Down Expand Up @@ -247,13 +247,13 @@
(books-by-author octavia books) => (just [wild-seed]))

(facts "author-by-name"
(author-by-name "Octavia E. Butler" authors) => octavia
(author-by-name "Octavia E. Butler" authors-set) => octavia
(author-by-name "Octavia E. Butler" #{felleisen, friedman}) => nil
(author-by-name "China Miéville" authors) => china
(author-by-name "Goerge R. R. Martin" authors) => nil)
(author-by-name "China Miéville" authors-set) => china
(author-by-name "Goerge R. R. Martin" authors-set) => nil)

(facts "living-authors"
(living-authors authors) => (just #{china, felleisen, friedman})
(living-authors authors-set) => (just #{china, felleisen, friedman})
(living-authors #{octavia}) => (just #{})
(living-authors #{china, felleisen}) => (just #{china, felleisen}))

Expand Down

0 comments on commit c6d2de3

Please sign in to comment.