-
Notifications
You must be signed in to change notification settings - Fork 113
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
Add tests and refactor #40
base: master
Are you sure you want to change the base?
Conversation
Maybe I can do this incrementally. Unfortunately I don't have tests for existing work so I'd have to rely on new tests being good. |
This can be used as a jest guide too |
const { License } = require('../components/license.js') | ||
|
||
test('MIT license badge title displays correctly', () => { | ||
var license = new License('MIT') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here I made License its own object.
This is actually not that important to me - I had the app working fine as is for license.
This might be a throwaway branch and PR but the idea was to write the ideal API using tests.
This does mean a long and slow refactor which is only usable when it is merged.
UPDATE: Some of the markdown and repo stuff might still be useful