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

fix(tool): add asserts to changelog code to make it less fragile. #972

Merged
merged 1 commit into from
Nov 20, 2015

Conversation

erwinmombay
Copy link
Member

No description provided.

@erwinmombay erwinmombay force-pushed the changelog-assert branch 2 times, most recently from 3be4260 to 3ff2d90 Compare November 19, 2015 19:54
@@ -69,6 +70,7 @@ function getGitMetadata() {
}

function submitReleaseNotes(version, changelog) {
assert(typeof version == 'number', 'version should be a number.');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here and elsewhere output the broken value into the assert.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

return submitReleaseNotes(version, gitMetadata.changelog);
})
.catch(errHandler);
}

function submitReleaseNotes(version, changelog) {
assert(typeof version == 'number', 'version should be a number. ' + version);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Supports %s interpolation

@cramforce
Copy link
Member

LGTM with one comment

erwinmombay added a commit that referenced this pull request Nov 20, 2015
fix(tool): add asserts to changelog code to make it less fragile.
@erwinmombay erwinmombay merged commit 44d0e13 into ampproject:master Nov 20, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants