Skip to content

Commit

Permalink
Remove coverage step
Browse files Browse the repository at this point in the history
suppress eslint errors
  • Loading branch information
jstvz committed Nov 11, 2024
1 parent 67f760f commit f6e88f8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 48 deletions.
40 changes: 0 additions & 40 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,43 +80,3 @@ jobs:
path: |
.coverage
coverage.xml
coverage:
name: Coverage
needs: [frontend, backend]
runs-on: SFDO-Tooling-Ubuntu
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: ./.github/setup-docker-compose
with:
omniout-token: ${{ secrets.OMNIOUT_TOKEN }}
- name: Download frontend coverage artifacts
uses: actions/download-artifact@v3
with:
name: frontend-coverage
path: coverage
- name: Download backend coverage artifacts
uses: actions/download-artifact@v3
with:
name: backend-coverage
- name: Upload coverage reports
if: env.COVERALLS_REPO_TOKEN
# prettier-ignore
run: >
docker-compose run
-e COVERALLS_REPO_TOKEN
-e COVERALLS_PARALLEL=true
-e COVERALLS_SERVICE_NUMBER="${{ github.run_id }}"
-e CI_BUILD_NUMBER="${{ github.run_id }}"
--no-deps
web bash -c '
yarn test:js:report-coverage &&
yarn test:py:report-coverage &&
python -m coveralls --finish
'
- name: Check coverage
run: |
docker-compose run --no-deps web yarn test:js:check-coverage
docker-compose run --no-deps web yarn test:py:check-coverage
17 changes: 9 additions & 8 deletions src/js/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import { createSocket } from '@/js/utils/websockets';

const history = createBrowserHistory();

console.log('>>> index.tsx');
log('>>> index.tsx');

const App = () => (
<DocumentTitle title={window.SITE_NAME}>
Expand Down Expand Up @@ -100,27 +100,28 @@ init_i18n((i18nError?: string) => {
log(i18nError);
}
const el = document.getElementById('app');
console.log('>>> fetched app element');
log('>>> fetched app element');
if (el) {
// Remove scratch org UUID from URL
const scratchOrgUUID = getUrlParam(SCRATCH_ORG_QS);
if (scratchOrgUUID) {
history.replace({ search: removeUrlParam(SCRATCH_ORG_QS) });
}

console.log('>>> creating app store');
log('>>> creating app store');
// Create store
const appStore = createStore(
reducer,
undefined,
composeWithDevTools(
// eslint-disable-next-line
// @ts-ignore
applyMiddleware(thunk.withExtraArgument(history), logger),
),
);
console.log('>>> appStore created');
log('>>> appStore created');

console.log('>>> connecting to websocket server');
log('>>> connecting to websocket server');
// Connect to WebSocket server
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
const host = window.location.host;
Expand All @@ -133,7 +134,7 @@ init_i18n((i18nError?: string) => {
},
},
});
console.log('>>> connected to websocket server');
log('>>> connected to websocket server');

// Get JS globals
let GLOBALS = {};
Expand Down Expand Up @@ -178,7 +179,7 @@ init_i18n((i18nError?: string) => {

// Set App element (used for react-SLDS modals)
settings.setAppElement(el);
console.log('>>> about to fetch products');
log('>>> about to fetch products');
// Fetch products before rendering App
(appStore.dispatch as ThunkDispatch)(fetchProducts()).finally(() => {
(appStore.dispatch as ThunkDispatch)(fetchOrgJobs());
Expand All @@ -201,6 +202,6 @@ init_i18n((i18nError?: string) => {
</Provider>,
);
});
console.log('>>> fetched products');
log('>>> fetched products');
}
});

0 comments on commit f6e88f8

Please sign in to comment.