Skip to content

Ci documentation added #762

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

Merged
merged 10 commits into from
Nov 16, 2018
Merged

Ci documentation added #762

merged 10 commits into from
Nov 16, 2018

Conversation

OPpuolitaival
Copy link
Contributor

No description provided.

@OPpuolitaival
Copy link
Contributor Author

@0xc0170 @adbridge please review

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 9, 2018

@ARMmbed/mbed-os-maintainers

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 9, 2018

@bulislaw pls review


### Travis CI

In Mbed OS [Travis CI](https://travis-ci.org/) is used as primary automatic testing and checking run environment.
Copy link
Contributor

Choose a reason for hiding this comment

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

can we point here to our Travis page (mbed-os one) ?


In Mbed OS [Travis CI](https://travis-ci.org/) is used as primary automatic testing and checking run environment.

Travis configuration is located in .travis.yml file in Mbed OS root directory. Mbed OS use public travis so test results are publicly available and there are public [documentation available](https://docs.travis-ci.com/).
Copy link
Contributor

Choose a reason for hiding this comment

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

reference here our .travis.ymls file (url)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@AnotherButler is it OK to add this url? It is so many times commented that do not link to the github

In Mbed OS [Travis CI](https://travis-ci.org/) is used as primary automatic testing and checking run environment.

Travis configuration is located in .travis.yml file in Mbed OS root directory. Mbed OS use public travis so test results are publicly available and there are public [documentation available](https://docs.travis-ci.com/).

Copy link
Contributor

Choose a reason for hiding this comment

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

What kind of tests jenkins runs?

Should travis also explain each jobs : docs, astyle etc ? like below in the jenkins?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point!

@bulislaw
Copy link
Member

@screamerbg first stab at documenting CI testing as we discussed some time ago

Copy link
Member

@bulislaw bulislaw left a comment

Choose a reason for hiding this comment

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

It focuses mainly on the tools we use rather than what sort of test we run, could we expand on the details?

@OPpuolitaival
Copy link
Contributor Author

@bulislaw better now?

@AnotherButler
Copy link
Contributor

@0xc0170 Do those changes resolve all of your comments?

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 19, 2018

@0xc0170 Do those changes resolve all of your comments?

I'll review shortly, and send feedback

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 19, 2018

@ashok-rao @MarceloSalazar Can you review this addition?

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 22, 2018

Note, there's upcoming update to the mbed ci job, that will depend on these changes.

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 22, 2018

Note, there's upcoming update to the mbed ci job, that will depend on these changes.

@MarceloSalazar
Copy link
Contributor

Looks good, however, this is something for @screamerbg to have a look and comment

@OPpuolitaival
Copy link
Contributor Author

Latest changes are not visible in web UI because of problems in github. You can review by fetching the branch by using git.

@0xc0170
Copy link
Contributor

0xc0170 commented Oct 24, 2018

@AnotherButler Can you review? I'll poke @ARMmbed/mbed-os-maintainers to get more reviews here.

Let's progress this important document (more updates are coming this way in the following days)

Copy link
Contributor

@NirSonnenschein NirSonnenschein left a comment

Choose a reason for hiding this comment

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

looks pretty good, please see my comments (mostly small text fixups)


### Jenkins

[Jenkins](https://jenkins.io/) is used to run tests behind firewall. There are multiple reasons to run tests in Jenkins but typically those are related to high amount of concurrent builds or shared secrets.
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not sure about what you are trying to say with this paragraph, is it a description of what Jenkins is? is it a description of what we use Jenkins for? is it a justification of the use of Jenkins.
this seems to be a mix of all three, and it is not really clear what you are trying to say. in the Travis section above it is more clearly about what we use Travis for (and to a lesser extent how).

[Jenkins](https://jenkins.io/) is used to run tests behind firewall. There are multiple reasons to run tests in Jenkins but typically those are related to high amount of concurrent builds or shared secrets.

#### How it works:
* Jenkins uses [scripted pipeline syntax](https://jenkins.io/doc/book/pipeline/)
Copy link
Contributor

Choose a reason for hiding this comment

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

Jenkins uses [scripted pipeline syntax] => Jenkins uses a [scripted pipeline syntax]


#### How it works:
* Jenkins uses [scripted pipeline syntax](https://jenkins.io/doc/book/pipeline/)
* There is Jenkinsfile in Mbed OS root folder but that is just trigger for tests. Jenkins scripts are not publicly available at the moment.
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 flip the order of these two sentences

#### How it works:
* Jenkins uses [scripted pipeline syntax](https://jenkins.io/doc/book/pipeline/)
* There is Jenkinsfile in Mbed OS root folder but that is just trigger for tests. Jenkins scripts are not publicly available at the moment.
* Jenkins select required tests dynamically based on the code changes. For example. no tests are executed if only markdown (.md) file changes
Copy link
Contributor

Choose a reason for hiding this comment

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

Jenkins select => Jenkins selects

maybe also
For example. => For example:

Copy link
Contributor

Choose a reason for hiding this comment

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

if only markdown (.md) file changes => if only markdown (.md) files are changed

* Jenkins uses [scripted pipeline syntax](https://jenkins.io/doc/book/pipeline/)
* There is Jenkinsfile in Mbed OS root folder but that is just trigger for tests. Jenkins scripts are not publicly available at the moment.
* Jenkins select required tests dynamically based on the code changes. For example. no tests are executed if only markdown (.md) file changes
* Jenkins run first small amount of tests to provide fast feedback and then more tests
Copy link
Contributor

Choose a reason for hiding this comment

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

Jenkins run first small amount => Jenkins first runs small amount
also maybe:
more tests => additional tests

* **jenkins-ci/greentea-test** - Run [greentea tests](/docs/tools/testing/testing_greentea.html)
* **jenkins-ci/mbed2-build-ARM** - Build Mbed OS 2 with ARM
* `python tools/build_release.py -p <target> -t <toolchain>`
* **jenkins-ci/mbed2-build-GCC_ARM** - Build Mbed OS 2 with GCC_ARM. Related commands:
Copy link
Contributor

Choose a reason for hiding this comment

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

no related commands after "Related commands:"

@@ -186,7 +186,7 @@ Time: 3 days for reviewers to leave feedback after the maintainers add the "need

#### The CI (Continuous Integration) testing

There are many CI systems available. Which CI tests we run against a particular pull request depends on the effect that pull request has on the code base. Irrespective of which CI tests run, Mbed OS has an all green policy, meaning that all the CI jobs that are triggered must pass before we merge the pull request.
There are many [CI systems available](/docs/reference/contributing/guidelines/ci.html). Which CI tests we run against a particular pull request depends on the effect that pull request has on the code base. Irrespective of which CI tests run, Mbed OS has an all green policy, meaning that all the CI jobs that are triggered must pass before we merge the pull request.
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 add what the CI systems are available for (e.g. There are many [CI systems available] for testing Mbed OS pull requests)


In Mbed OS [Travis CI](https://travis-ci.org/ARMmbed/mbed-os) is used as primary automatic testing and checking run environment.

Travis configuration is located in [.travis.yml](https://github.com/ARMmbed/mbed-os/blob/master/.travis.yml) file in Mbed OS root directory. Mbed OS use public travis so test results are publicly available and there are public [documentation available](https://docs.travis-ci.com/).
Copy link
Contributor

Choose a reason for hiding this comment

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

Travis configuration is located in .travis.yml=> The Travis configuration is located in the .travis.yml file


In Mbed OS [Travis CI](https://travis-ci.org/ARMmbed/mbed-os) is used as primary automatic testing and checking run environment.

Travis configuration is located in [.travis.yml](https://github.com/ARMmbed/mbed-os/blob/master/.travis.yml) file in Mbed OS root directory. Mbed OS use public travis so test results are publicly available and there are public [documentation available](https://docs.travis-ci.com/).
Copy link
Contributor

Choose a reason for hiding this comment

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

Mbed OS use public travis => Mbed OS uses public travis

Copy link
Contributor

@NirSonnenschein NirSonnenschein left a comment

Choose a reason for hiding this comment

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

Thanks, looks even better now.

@AnotherButler
Copy link
Contributor

Query: How often do we add, remove or change tests?

@cmonr
Copy link
Contributor

cmonr commented Oct 25, 2018

Query: How often do we add, remove or change tests?

Making a context check here that tests here refer to PR merge checks

Not often. It's under flux right now because we're @OPpuolitaival's team is getting the new CI up and running. Travis CI and Jenkins don't change often.

@AnotherButler
Copy link
Contributor

So we don't expect to update these files every feature release or more?

@cmonr
Copy link
Contributor

cmonr commented Oct 25, 2018

I would think not.
I should hope not?

@OPpuolitaival
Copy link
Contributor Author

@AnotherButler There will be changes at least in next 6 months because there are a lot of tests which are missing and we start adding those when base tests are stable.

#### Tests

* **continuous-integration/jenkins/pr-head** Jenkins main pipeline script execution status
* **jenkins-ci/build-ARM** - Build Mbed OS and examples with ARM. Related commands:
Copy link
Contributor

Choose a reason for hiding this comment

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

@ARMmbed/mbed-os-maintainers What do you think about these checks inthe PR ?

My vote would be as it is now (build, exporters, mbed 2 build, test) rather than each toolchain own one (would end up with 20 checks?)

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't see a particular problem with having up to 20 merge checks.
Plus, I think it would complicate the pipeline a bit to have the subjobs merge reporting after the fact.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@cmonr reporting is done already.. sub jobs report the status on checks and main pipeline send the summary post in the end of run.

Make initial edits to file.
Copy link
Contributor

@AnotherButler AnotherButler left a comment

Choose a reason for hiding this comment

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

Please address my queries.

#### Tests

- **continuous-integration/jenkins/pr-head** - Jenkins main pipeline script execution status.
- **jenkins-ci/build-ARM** - Build Mbed OS and examples with ARM. Related commands:
Copy link
Contributor

Choose a reason for hiding this comment

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

Query: What does it mean that this builds with ARM?

- **jenkins-ci/exporter** - Export and build exported code. Related commands:
- `python -u mbed-os/tools/test/examples/examples.py export <exporter> --mcu <target>`.
- **jenkins-ci/greentea-test** - Run [greentea tests](/docs/tools/testing/testing_greentea.html).
- **jenkins-ci/mbed2-build-ARM** - Build Mbed OS 2 with ARM. Related commands:
Copy link
Contributor

Choose a reason for hiding this comment

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

Query: What does it mean that this builds with ARM?

Copy link
Contributor

Choose a reason for hiding this comment

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

Think it means arm-compiler


#### Tests

- **continuous-integration/travis-ci/pr** - Main run main.
Copy link
Contributor

Choose a reason for hiding this comment

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

What does this mean?

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not sure how to clarify this. Could someone please explain what this means?

Copy link
Contributor

Choose a reason for hiding this comment

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

This job is the main job that runs all of the other travis-ci sub-jobs. Not sure what kind of wording would work for this.

Copy link
Contributor

Choose a reason for hiding this comment

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

"Run other testing jobs."?

Copy link
Contributor

Choose a reason for hiding this comment

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

Does this phrasing work?

Copy link
Contributor

Choose a reason for hiding this comment

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

Bump

Copy link
Contributor

Choose a reason for hiding this comment

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

@OPpuolitaival Do you think you could clarify this? Looks like it should be the last thing for this PR.

Copy link
Contributor

Choose a reason for hiding this comment

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

I went with the phrasing I suggested. If you have another suggestion, please put up a new PR.

Olli-Pekka Puolitaival and others added 3 commits October 31, 2018 18:12
@AnotherButler AnotherButler merged commit 2971803 into ARMmbed:development Nov 16, 2018
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.

7 participants