I have set up Jenkins to use the GitHub pull request builder. It's working great! Except one little thing. My test suite creates HTML Reports (which I have beautifully posted using the HTML result poster plugin) but I can't seem to change the status message that gets posted to GitHub. My commits all get marked like:
The status of the commit gets updated properly, but the message part always says "Build finished. No test results found."
I can't seem to figure out how to change this message based on the status of the test suite. So, basically the only feedback I'm getting is the exit status of my shell script. This script does all of the building, testing, and handling of results, etc. This is reasonably acceptable in the event of a pass, but in the event of a failure, this message could be much more helpful! Even just knowing whether it was a build failure vs. a test suite failure would be nice, so then I can adequately verbally abuse the person who made the pull request :).
Everything else is working so good, that I can't figure out what seems like a trivial change is driving me crazy! Any ideas?
FWIW, the logic was added here: https://github.com/janinko/ghprb/commit/ffbc581d2712d6b99b9c6d0b081d7895a5ee8039
I believe you just need to generate JUnit formatted test output, and you may or may not need to ad a post-build step to publish the JUnit XML output.
Related
Tech writers are going to edit text in JSON files via github in our project. Since they never used a IDE (and don't need to) we think about using the web GUI of github. We have a CI, but it would be very cool, if we could run a check before the commit gets done.
Example:
Step 1: tech writer opens in github the JSON file
Step 2: tech writer updates a string
Step 3: tech writer presses button to save the changes
Step 4: Some simple script executes and checks the content of this particular file.
Step 5a: Everything fine? Then commit - END
Step 5b: There is a syntax error. Show the error message to the tech writer.
Is this possible?
GitHub doesn't provide this functionality, and it's not likely anyone else does, either.
In order to do this, GitHub would have to have a non-bare repository on their servers and let you run an arbitrary script. Bare repositories are packed and can be much smaller than a full working tree, and even if GitHub had a working tree, it wouldn't necessarily be on your branch, which would delay the process. Running an arbitrary script is a security risk, and it's not guaranteed that your script would run fast enough for the process to complete in a reasonable amount of time. Your script would also need to run via the API, which has hard limits on response times.
There is GitHub Actions, which lets you do this, but that doesn't provide real-time checking like you want. It is appropriately sandboxed and single use so you can arbitrary scripts.
I should note that Git also doesn't provide real-time checking here: the best it can do is pre-commit hooks to prevent you from committing bad changes (if you've chosen to enable them).
We are currently checking the test plan module on our Azure Devops server and I'm facing an issue that the community may help.
According to this once a test run has been marked as failed or blocked there is no way to resume the test once the raised defects have been resolved. You either have to mark the test run as paused (so as to be granted the "resume" option) or reset the whole test to active in which case you loose all your progress and need to start over. Two questions:
This "workaround" works as long as you are careful and save the test run as paused. Otherwise if a failed step exists the run is saved as failed. Once this is done I have found no way of changing it to "paused" so as to get the resume option. Is there a way I'm missing?
In the test list under a specific suite you get the current test run outcome and state of test case. In case of "Paused" you don't have a way to know if the test execution is paused or you are utilizing the aforementioned workaround (e.g. a bug is registered). I cannot see a way that I could enhance the test run with some information that would signal this (there is no wit template I have found) on the grid. So is the standard query module (bringing testcases and associated bugs with state) the only way?
thanks
For the first question, if the test case is on status Failed and you retest the test case, all test steps need to be redone. Also there is no resume-button. This is by design. For now, set the status to Paused can resume the test, but it cannot truly reflect the result. As far as I know, there is no other way.
You could add your request for this feature(For example: when status = Failed/Block, the restore button is enable) on our UserVoice site , which is our main forum for product suggestions.After suggest raised, you can vote and add your comments for this feedback. The product team would provide the updates if they view it.
For the second question, as workaround , you can also add tags to paused test cases for labeling.
I was writing a small integration for github (https://github.com/ligi/kontinuum) which works fine when using with the user that I created it with. Now I wanted to use this integration for an organisation - unfortunately I get the following error when trying to write a status for a commit:
{"message":"Resource not accessible by integration","documentation_url":"https://developer.github.com/v3"}
Reading the documentation there I do not see why writing a status should not work in this context. I think this might be a bug - posting this here as a first stage to a potential bug-report (anyone knows where to report github integration bugs?) and the search for a workaround.
I am working on a large project with a number of other developers.
We have implement JSHint which will throw an error when grunt build is run if the JavaScript does not pass the Lint.
I would like to know if it is possible to integrate directly with Github so that a Pull Request will not be allowed to be merged unless it passes in JSHint.
Is there a way or tool to do this?
You can't prevent pull requests from being merged; however, you can automatically run JSLint using Travis-CI, which will put a big red X on pull requests that do not pass JSLint. Hopefully this is enough to stop people from merging these pull requests.
This blog post gives a good introduction to running grunt tasks on Travis-CI.
There is a free way to do it too by lint-review
As #tbekolay said, it puts a red sign.
Also, you will see the problems as comments on the code wich is super cool.
But you can merge it manually.
I have a workflow that that runs to update the status of a Case record to Resolved. However, the workflow gets put into status 'waiting' and contains a generic error message. When looking at the system job message it says:
This has worked on another system (as all I am doing is updating a status) so I assume it has something to do with the customizations in place.
Has anyone else ever come across this and how did you resolve it?
Thanks in advance
UPDATE:
I have created a new organisation to test out any possible solutions and to narrow down what might be happening.
I created a workflow on the blank organisation and a test case record to try it out on. It worked fine as expected.
I then imported the customizations that are on my customers system. Did the same again and it worked fine.
I then created a new case record and tried the original workflow, this did not work.
I then added a workflow that does the same as the first workflow and tried it on the pre customizations record, it worked.
I then tried the new workflow on the new record and once again this did not work.
It is therefore appearing that the workflows are not working on any records post customization import.
Has anyone come across this before, and what steps were taken to resolve?
Thanks again
If you have the possibility to look at the registered plugins, then search for a plugin registered on the message SetState or SetStateDynamicEntity for the entity case (incident).
I assume there is a plugin which fails in your case. This is the reason for your error message.