Skip to content

Commit

Permalink
fix: remove duplicate code which exists in chrisleekr#478
Browse files Browse the repository at this point in the history
  • Loading branch information
habibalkhabbaz committed Aug 18, 2022
1 parent b1b1495 commit 442ffb1
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 15 deletions.
12 changes: 0 additions & 12 deletions app/binance/__tests__/candles.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ describe('candles.js', () => {
let loggerMock;
let mongoMock;

let mockQueue;

let mockGetConfiguration;
let mockSaveCandle;

Expand Down Expand Up @@ -55,12 +53,6 @@ describe('candles.js', () => {
return mockWebsocketCandlesClean;
});

mockQueue = {
executeFor: jest.fn().mockResolvedValue(true)
};

jest.mock('../../cronjob/trailingTradeHelper/queue', () => mockQueue);

jest.mock('../../cronjob/trailingTradeHelper/common', () => ({
saveCandle: mockSaveCandle
}));
Expand Down Expand Up @@ -234,9 +226,5 @@ describe('candles.js', () => {
]
);
});

it('triggers queue.executeFor for ETHBTC', () => {
expect(mockQueue.executeFor).toHaveBeenCalledWith(loggerMock, 'ETHBTC');
});
});
});
3 changes: 0 additions & 3 deletions app/binance/candles.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
const _ = require('lodash');
const queue = require('../cronjob/trailingTradeHelper/queue');
const { binance, mongo } = require('../helpers');
const {
getConfiguration
Expand Down Expand Up @@ -111,8 +110,6 @@ const syncCandles = async (logger, symbols) => {
}));

await mongo.bulkWrite(logger, 'trailing-trade-candles', operations);

queue.executeFor(logger, symbol);
};

return getCandles();
Expand Down

0 comments on commit 442ffb1

Please sign in to comment.