-
Notifications
You must be signed in to change notification settings - Fork 32
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
Make PageSpeed Insights part of CI #486
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
|
@@ -68,6 +68,10 @@ module.exports = function(grunt) { | |
output: 'dist/data' | ||
} | ||
} | ||
}, | ||
|
||
psiNgrok: { | ||
marionette: {} | ||
} | ||
}); | ||
}; |
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 |
---|---|---|
@@ -0,0 +1,25 @@ | ||
var psiNgrok = require('psi-ngrok'); | ||
|
||
module.exports = function(grunt) { | ||
grunt.registerMultiTask('psiNgrok', function() { | ||
var async = this.async; | ||
|
||
grunt.event.once('connect.server.listening', function(host, port) { | ||
psiNgrok({ | ||
pages: ['/', 'additional-resources', 'downloads', 'docs/current', 'updates'], | ||
onError: function(error) { | ||
grunt.fatal(error) | ||
}, | ||
port: port, | ||
options: { | ||
//@todo up it to 85-90 when pages speed will be fixed | ||
threshold: 10 | ||
} | ||
}).then(function() { | ||
var done = async(); | ||
|
||
done(); | ||
}); | ||
}); | ||
}); | ||
}; |
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
What's the impact on testing runtime?
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.
I think impact is not so much but it worth it. Right now we have issue about page speed #394 After fixing it I really don't wanna go back and fix it once more. If someone propose changes which downgrade pagespeed then CI automatically fail it.
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.
Or maybe you asking about purpose of adding
threshold: 10
so low. I think to add PSI asap to already have it.threshold
can be increased after next pr's with pagespeed fixes.Also it helpful for testing during developing pagespeed fixes.
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.
I think I was referring more to your TODO there - it sounds like PageSpeed is having some impact on the build times and I was curious as to whether it would cause issues in future.
With the threshold being low, what's needed to bring it up?
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.
Ideally pages have to have
threshold
about 85, but right now on some pages it's lower. So value is setthreshold: 10
to successfully pass the build process. When page speed will be fixed we can up it.Other then that, it will be not run during deploy, so it's only just for checking new changes.
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.
Ohh I see, it's related to scoring. For some reason I though threshold was related to a number of pages to run through it! My bad :P
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.
No problem 👍