Skip to content

Commit

Permalink
Remove old CI files and rename integrations.yml to lint-unit.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
felixsch committed Feb 6, 2024
1 parent 87169e8 commit 4fb683d
Show file tree
Hide file tree
Showing 14 changed files with 46 additions and 347 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,5 @@ jobs:
- name: Run version checks
run: |
echo "::group::Version verification checks"
ruby integration/ci_check.rb
ruby ci/check-version-matches.rb
echo "::endgroup::"
23 changes: 0 additions & 23 deletions Jenkinsfile

This file was deleted.

45 changes: 44 additions & 1 deletion ci/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,46 @@
## RMT CI setup

tbd
Our CI setup runs the following steps:

### Lint and unit tests

workflow definition: [.github/workflows/lint-unit.yml](https://github.com/SUSE/rmt/blob/master/.github/workflows/lint-unit.yml)

This workflow runs rubocop to check if the source is well formated and afterwards unit tests and engine unit tests. At last it checks
if version in RMT and the rpm spec file matches.

**Running it locally**

There is no special mechanism needed to run these steps locally. Check the workflow for hints how to run unit tests

### CLI feature tests

workflow definition: [.github/workflows/features.yml](https://github.com/SUSE/rmt/blob/master/.github/workflows/features.yml)

This workflow runs our simple CLI feature tests und build the rpm beforehand to see the system working with an installed RMT rpm.

**Running it locally**

To run feature tests locally, you need:

- A checkout of RMT
- A running mysql database
- Proxy credentials to synchronize product information with SCC

```
# Fetch the CI container
$ export IMAGE="registry.opensuse.org/systemsmanagement/scc/containers/15.5/rmt-ci-container:latest"
# Build RMT rpms with the CI container the resulting rpms are in tmp/artifacts/
$ docker run --rm -it -v $(pwd):/usr/src/rmt-server $IMAGE 'ci/rmt-build-rpm'
# Run feature tests in the CI container
# Note: Running --network=host isn't stricly required if you setup mysql access otherwise
$ docker run --rm -it -v $(pwd):/usr/src/rmt-server --network=host $IMAGE bash -c 'ci/rmt-build-rpm && ci/rmt-configure && ci/rmt-run-feature-tests'
```

### The CI container

Our CI container is built here: https://build.opensuse.org/package/show/systemsmanagement:SCC:containers/rmt-ci-container

On push to Github master the rebuilt of the container is triggered
1 change: 1 addition & 0 deletions integration/ci_check.rb → ci/check-version-matches.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#! /usr/bin/env ruby

def modified_files
`git fetch origin master`
`git diff --name-only origin/master`.strip.split "\n"
Expand Down
8 changes: 0 additions & 8 deletions ci/rmt-console

This file was deleted.

37 changes: 0 additions & 37 deletions integration/Dockerfile.test

This file was deleted.

27 changes: 0 additions & 27 deletions integration/Jenkinsfile

This file was deleted.

15 changes: 0 additions & 15 deletions integration/create-oscrc.sh

This file was deleted.

11 changes: 0 additions & 11 deletions integration/create-rmt-conf.sh

This file was deleted.

16 changes: 0 additions & 16 deletions integration/install.sh

This file was deleted.

5 changes: 0 additions & 5 deletions integration/prophet/.prophet_ci.yml

This file was deleted.

115 changes: 0 additions & 115 deletions integration/prophet/ci_executor.rb

This file was deleted.

66 changes: 0 additions & 66 deletions integration/prophet/prophet.rb

This file was deleted.

Loading

0 comments on commit 4fb683d

Please sign in to comment.