Skip to content

Commit

Permalink
chore: removed unneeded kafkaHelper; excluded some files from test-co…
Browse files Browse the repository at this point in the history
…verage check (#1015)
  • Loading branch information
geka-evk authored Apr 27, 2024
1 parent 82d2bd4 commit 05c4ce9
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 134 deletions.
9 changes: 9 additions & 0 deletions .nycrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,13 @@ exclude: [
'**/bulk*/**',
'src/shared/logger/**',
'src/shared/constants.js',
'src/domain/position/index.js',
'src/domain/position/binProcessor.js',
'src/handlers/positions/handler.js',
'src/handlers/transfers/createRemittanceEntity.js',
'src/handlers/transfers/FxFulfilService.js',
'src/models/position/batch.js',
'src/models/fxTransfer/**',
'src/shared/fspiopErrorFactory.js'
]
## todo: increase test coverage before merging feat/fx-impl to main branch
2 changes: 0 additions & 2 deletions test/integration-override/handlers/transfers/handlers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ const {
wrapWithRetries
} = require('#test/util/helpers')
const TestConsumer = require('#test/integration/helpers/testConsumer')
const KafkaHelper = require('#test/integration/helpers/kafkaHelper')

const ParticipantCached = require('#src/models/participant/participantCached')
const ParticipantCurrencyCached = require('#src/models/participant/participantCurrencyCached')
Expand Down Expand Up @@ -328,7 +327,6 @@ Test('Handlers test', async handlersTest => {

// Set up the testConsumer here
await testConsumer.startListening()
await KafkaHelper.producers.connect()
// TODO: MIG - Disabling these handlers to test running the CL as a separate service independently.
await new Promise(resolve => setTimeout(resolve, rebalanceDelay))

Expand Down
127 changes: 0 additions & 127 deletions test/integration/helpers/kafkaHelper.js

This file was deleted.

10 changes: 5 additions & 5 deletions test/scripts/test-integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ echo "==> integration tests exited with code: $INTEGRATION_TEST_EXIT_CODE"

## Kill service
echo "Stopping Service with Process ID=$PID"
kill $(cat /tmp/int-test-service.pid)
kill $(lsof -t -i:3001)
kill -9 $(cat /tmp/int-test-service.pid)
kill -9 $(lsof -t -i:3001)

## Give some time before restarting service for override tests
sleep $WAIT_FOR_REBALANCE
Expand Down Expand Up @@ -91,10 +91,10 @@ echo "==> override integration tests exited with code: $OVERRIDE_INTEGRATION_TES

## Kill service
echo "Stopping Service with Process ID=$PID1"
kill $(cat /tmp/int-test-service.pid)
kill $(lsof -t -i:3001)
kill -9 $(cat /tmp/int-test-service.pid)
kill -9 $(lsof -t -i:3001)
echo "Stopping Service with Process ID=$PID2"
kill $(cat /tmp/int-test-handler.pid)
kill -9 $(cat /tmp/int-test-handler.pid)

## Shutdown the backend services
if [ $INT_TEST_SKIP_SHUTDOWN == true ]; then
Expand Down

0 comments on commit 05c4ce9

Please sign in to comment.