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

Add automatic tests to the project #101

Merged
merged 8 commits into from
Jan 29, 2020
Merged

Add automatic tests to the project #101

merged 8 commits into from
Jan 29, 2020

Conversation

krufab
Copy link
Contributor

@krufab krufab commented Jan 17, 2020

Added tests to the project, as per issue #100

Signed-off-by: Fabio Kruger <krufab@gmail.com>
@krufab krufab requested a review from a team as a code owner January 17, 2020 00:31
@krufab krufab changed the title Added tests the project Added tests to the project Jan 17, 2020
@slide
Copy link
Member

slide commented Jan 17, 2020

The problem is that you aren't a trusted contributor, so the CI will not use your Jenkinsfile changes.

Copy link
Member

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

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

I am fine with introducing some smoke tests in the repository. OTOH it might be preferable to consider doing real integration tests. It might require using a more advanced test framework, e.g. for putting Jenkins into testcontainers

tests/tests.bats Show resolved Hide resolved
tests/tests.bats Outdated Show resolved Hide resolved
@krufab
Copy link
Contributor Author

krufab commented Jan 17, 2020

@oleg-nenashev, there is an integration test in jnlp-slave.
I agree integration tests would be useful as well. However they might come later on...

@slide , i'll revert the build.sh so that the tests can be executed

@slide
Copy link
Member

slide commented Jan 17, 2020

@krufab I was not saying that you should revert build.sh, I am just telling you why the CI is failing. What I can do is submit a shadow PR with your same changes so that the CI will actually run using the Jenkinsfile changes, would that be ok with you?

@krufab
Copy link
Contributor Author

krufab commented Jan 17, 2020

@slide, I guess it's ok, yes

@slide
Copy link
Member

slide commented Jan 17, 2020

@krufab See #102

Fabio Kruger added 2 commits January 17, 2020 20:55
Signed-off-by: Fabio Kruger <krufab@gmail.com>
Signed-off-by: Fabio Kruger <krufab@gmail.com>
@krufab
Copy link
Contributor Author

krufab commented Jan 18, 2020

@slide, Bats doesn't seem to be installed on the test server. I reverted the build.sh file, removed make tests and now it builds. You can run the tests on your local machine and check if they are ok. When the build server will be able to run the tests, I'll re-enable them.

@slide
Copy link
Member

slide commented Jan 18, 2020

If you look at the master docker repo, you can see that bats is a submodule. That would be the way to go here too.

build.sh Show resolved Hide resolved
@slide
Copy link
Member

slide commented Jan 21, 2020

I pulled in all the latest changes into my duplicate PR so we can see the Jenkinsfile changes in action

@slide
Copy link
Member

slide commented Jan 21, 2020

#102 is passing for all the checks including the tests

@krufab
Copy link
Contributor Author

krufab commented Jan 27, 2020

Is it ok this PR or is there anything to change?

@slide
Copy link
Member

slide commented Jan 27, 2020

I am happy with this, if @oleg-nenashev has no objections, I think it can be merged. I will look at adding some simple pester based tests for the Windows side.

@oleg-nenashev oleg-nenashev self-requested a review January 29, 2020 16:01
Copy link
Member

@oleg-nenashev oleg-nenashev left a comment

Choose a reason for hiding this comment

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

Thanks!

@oleg-nenashev oleg-nenashev merged commit 098db9a into jenkinsci:master Jan 29, 2020
@oleg-nenashev oleg-nenashev changed the title Added tests to the project Add tests to the project Jan 29, 2020
@oleg-nenashev oleg-nenashev changed the title Add tests to the project Add automatic tests to the project Jan 29, 2020
@krufab krufab deleted the add_test_and_uniform_code branch January 30, 2020 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants