Contributions are welcome!
In practice, all contributions have come from Coursera employees (Courserians), and this documentation is weighted towards new Courserians wishing to contribute.
For others, the general workflow should be fine, but the final publication steps currently depend on Coursera internal actions, for example, checking that the change does not break our production system.
For bug fixes submit a pull request. Be sure to include how to reproduce the bug, ideally with a test case.
For improvements and features, first open a github issue describing the planned change and discuss it.
Courserians should join the internal #courier slack channel.
-
Is intended for new developers getting started.
-
Describes the various credentials you need for the full publishing workflow. This is intended for Courserians.
-
Shows how to find the currently published (and newly published) artifacts from this project. This presupposes that you have credentials.
-
Describes how to create both SNAPSHOT artifacts for integration testing, and the final published artifacts.
The maven-plugin and gradle-plugin are unmaintained.
-
Set your JAVA_HOME to a Java 8 SDK. We test with oraclejdk8.
-
Clone this repo.
-
Publish to the local ivy cache:
sbt publish-local
-
Cross compilation also is supported:
sbt +publish-local
-
This project also uses the convention of prefixing commands with
full
as a custom cross-version command, e.g.sbt fullpublish-ivylocal
You should not prefix these commands with the
sbt
+
or^
. -
Update any projects you would like to test to reference the SNAPSHOT that was published locally.
To run all tests, with all versions:
sbt fulltest
The bulk of the generator is tested by generator-test
.
It contains schemas in generator-test/src/main/pegasus
and contains uni tests against those schemas in generator-test/src/test/scala
.
These specific tests can be run via:
sbt test
SBT Plugin specific tests are defined under in the sbt-plugin
project at
sbt-plugin/src/sbt-test/courier-sbt-plugin
, using the scritped framework.
Each test is an actual SBT project with a series of tasks that are run and assertions made after those tasks have run.
These test can be run via:
sbt scripted
For details on these sbt plugin "scripted" tests, see: http://eed3si9n.com/testing-sbt-plugins
We use travis to test pull requests.
master
should be stable.- All code changes are reviewed by a committer.
- All code is covered by unit tests.
- Releases are published to Maven Central using semantic versioning.
- All changes are committed to the head of master as a single "squashed" commit, not merged.
- Full attribution to the pull request submitter is retained.
By contributing to Courier, you agree that your contributions will be licensed under Courier's Apache 2.0 License.