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

[WIP] Integration with Jenkins to display test results #238

Merged
merged 74 commits into from
Jul 22, 2016

Conversation

BenSummerfieldCowe
Copy link
Contributor

Made some changes for displaying results from jenkins (currently limited to jenkins only and only one level folder)

N440708 and others added 18 commits June 6, 2016 16:42
…st added handlebar helper that will be used to compare and display the results
…extra work for scenario outline, added a few temp css for it as well
… file, needs changing so its created automatically)
@jimCresswell
Copy link
Member

@BenSummerfieldCowe Hi Ben, looks good. Would you mind addressing the new Code Climate issues? It would also be nice if you could replace all the HTML strings with Handlebars templates, it's possible to pass an array, e.g. a list of Jenkins jobs, to a template (or partial) and have it iterate over the list for you. Shout if you need a hand or have any questions, I'm happy to help.

Other than that I am happy if @sponte is 😃 .

@BenSummerfieldCowe
Copy link
Contributor Author

@jimCresswell Hey Jim, thanks for the advice, will take at implementing suggestions and resolving Code Climate issues. I just had a chat with Stan as well and he gave some suggestions to make it less tied to jenkins. Will close this request and work on changes. Thanks

@jimCresswell
Copy link
Member

@BenSummerfieldCowe yep, Stan is good at architecture. If you want to make the changes in the same pull request that is fine, plus it gives us a record of the discussion and changes, absolutely up to you though!

thumbs up

* @return a promise for the repo metadata.
*/
function getResults(projectData) {
for(var j=0;j<projectData.config.jenkinsJobs.length;j++) {
Copy link
Member

Choose a reason for hiding this comment

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

Hey Ben,

Variables created with var are function scoped, the declaration (but not the assignment) will be hoisted to the top of the current function scope. So generally it's considered good form to not declare the variable in the loop but to put it at the top of the containing function. On the other hand, if you want block scoped variables that only exist within the loop you can declare them with the let keyword (assuming the application is running on a recent version of Node http://node.green/#let ).

@jimCresswell
Copy link
Member

Good progress, I made a couple of minor comments.

* Hits a url, calls a call back function and returns an array
*/
function httpGet(theUrl, callBack, async) {
var xmlHttp = new XMLHttpRequest();
Copy link
Contributor

Choose a reason for hiding this comment

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

I would recommend using https://www.npmjs.com/package/request-promise instead of XMLHttpRequest, it will make it easier to query external sources

@jimCresswell jimCresswell temporarily deployed to oss-specs-specs-eu-pr-238 July 15, 2016 10:41 Inactive
@sponte sponte merged commit 9a1b1f0 into oss-specs:master Jul 22, 2016
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.

None yet

3 participants