Skip to content

Commit 392605b

Browse files
authored
Merge pull request #3776 from project-koku/ci-reenable-coverage
CI - reenable coverage
2 parents b5aa7cb + 9f0d19a commit 392605b

File tree

2 files changed

+41
-19
lines changed

2 files changed

+41
-19
lines changed

.github/workflows/pull_request.yml

+25-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
1-
# Run this workflow for PRs only. Travis is required to push via insights-frontend-builder-common scripts
2-
31
name: Pull request
42
on:
53
pull_request:
6-
branches: [ main, master, prod-beta, prod-stable, stage-beta, stage-stable ]
4+
branches:
5+
- main
6+
- master
7+
- prod-beta
8+
- prod-stable
9+
- stage-beta
10+
- stage-stable
711
env:
812
BRANCH: ${{ github.base_ref }}
913

@@ -17,10 +21,12 @@ jobs:
1721
steps:
1822
- name: Checkout code
1923
uses: actions/checkout@v4
24+
2025
- name: Setup Node.js ${{ matrix.node-version }}
2126
uses: actions/setup-node@v4
2227
with:
2328
node-version: ${{ matrix.node-version }}
29+
2430
- name: Cache node modules
2531
id: cache-npm
2632
uses: actions/cache@v4
@@ -34,13 +40,28 @@ jobs:
3440
${{ runner.os }}-build-${{ env.cache-name }}-
3541
${{ runner.os }}-build-
3642
${{ runner.os }}-
43+
3744
- name: Install dependencies
3845
run: npm install
46+
3947
- name: Build
4048
run: npm run build
49+
4150
- name: Lint
4251
if: ${{ success() }}
4352
run: npm run lint
53+
4454
- name: Test
4555
if: ${{ success() }}
46-
run: npm test --coverage --maxWorkers=4
56+
run: npm test -- --collect-coverage --max-workers=4
57+
58+
- name: Upload coverage report
59+
if: ${{ success() }}
60+
uses: codecov/codecov-action@v4.2.0
61+
env:
62+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
63+
with:
64+
fail_ci_if_error: true
65+
directory: coverage
66+
plugin: pycoverage # Only run one plugin so that all do not run. There is no way to disable plugins entirely.
67+

README.md

+16-15
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
# Koku UI
22

3-
[![AGPLv3][license-badge]][license]
4-
[![Build Status][build-badge]][build]
3+
[![Apache 2.0][license-badge]](https://github.com/project-koku/koku-ui/blob/main/LICENSE)
4+
[![CI Status][build-badge]](https://github.com/project-koku/koku-ui/actions/workflows/tag_release.yml)
5+
[![codecov][codecov-badge]](https://codecov.io/gh/project-koku/koku-ui)
56

67
React.js app for Cost Management.
78

8-
User interface is based on Patternfly [![Patternfly][pf-logo]][patternfly]
9+
User interface is based on [Patternfly].
910

10-
To submit an issue, please visit https://issues.redhat.com/projects/COST/
11+
Submit issues in [Jira].
1112

1213
## Requirements
1314
* [NodeJS v18.15+][nodejs]
1415
* [npm v9.5+][npm]
1516

16-
## Setup /etc/hosts entries (do this once)
17+
## Setup `hosts` entries (do this once)
1718

18-
Edit the /etc/hosts file and add the following entries
19+
Edit the `/etc/hosts` file and add the following entries
1920
```
2021
127.0.0.1 prod.foo.redhat.com
2122
127.0.0.1 stage.foo.redhat.com
@@ -28,7 +29,7 @@ sudo bash scripts/patch-etc-hosts.sh
2829

2930
## Getting Started
3031
1. Install requirements listed above.
31-
2. Setup /etc/hosts entries listed above.
32+
2. Setup `/etc/hosts` entries listed above.
3233
3. Clone the repository, and open a terminal in the base of this project.
3334
4. Run the command `npm install` to install all the dependencies.
3435

@@ -109,7 +110,7 @@ npm start:static
109110
npm start:csb:mfe
110111
```
111112

112-
## Running local instances of Koku UI & Koku API
113+
## Running local instances of Koku UI and Koku API
113114
#### Koku UI
114115

115116
1. Start development server (Answer `yes` to run against local APIs)
@@ -193,14 +194,14 @@ http://localhost:1337/beta/settings/applications/cost-management
193194

194195
This [RELEASE][release-doc] doc describes how to release Koku UI to each staging environment.
195196

196-
[build]: https://travis-ci.com/project-koku/UI'
197-
[build-badge]: https://img.shields.io/travis/project-koku/koku-ui.svg?style=for-the-badge
197+
[build-badge]: https://github.com/project-koku/koku-ui/actions/workflows/tag_release.yml/badge.svg
198+
[license-badge]: https://img.shields.io/github/license/project-koku/koku-ui.svg?longCache=true
199+
[codecov-badge]: https://codecov.io/gh/project-koku/koku-ui/graph/badge.svg?token=1hjFIy1cRe
200+
198201
[koku-readme]: https://github.com/project-koku/koku#readme
199-
[license-badge]: https://img.shields.io/github/license/project-koku/koku-ui.svg?longCache=true&style=for-the-badge
200-
[license]: https://github.com/project-koku/koku-ui/blob/main/LICENSE
201202
[nodejs]: https://nodejs.org/en/
202203
[patch-etc-hosts]: https://github.com/RedHatInsights/insights-proxy/blob/master/scripts/patch-etc-hosts.sh
203-
[pf-logo]: https://www.patternfly.org/v4/images/logo.4189e7eb1a0741ea2b3b51b80d33c4cb.svg
204-
[patternfly]: https://www.patternfly.org/
204+
[Patternfly]: https://www.patternfly.org/
205205
[release-doc]: https://github.com/project-koku/koku-ui/blob/main/RELEASE.md
206-
[npm]: https://https://www.npmjs.com/
206+
[npm]: https://www.npmjs.com/
207+
[Jira]: https://issues.redhat.com/projects/COST/

0 commit comments

Comments
 (0)