Skip to content

Commit

Permalink
linter changes
Browse files Browse the repository at this point in the history
Signed-off-by: sumukhswamy <[email protected]>
  • Loading branch information
sumukhswamy committed Jan 24, 2025
1 parent d800b85 commit bf612d0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions server/routes/utils/__tests__/savedSearchReportHelper.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ describe('test create saved search report', () => {
test('create report with expected file name', async () => {
const hits: Array<{ _source: any }> = [];

Check warning on line 61 in server/routes/utils/__tests__/savedSearchReportHelper.test.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
const client = mockOpenSearchClient(hits);
const { timeCreated, fileName } = await createSavedSearchReport(
const { timeCreated: _timeCreated, fileName } = await createSavedSearchReport(

Check failure on line 63 in server/routes/utils/__tests__/savedSearchReportHelper.test.ts

View workflow job for this annotation

GitHub Actions / Lint

Replace `·timeCreated:·_timeCreated,·fileName` with `⏎······timeCreated:·_timeCreated,⏎······fileName,⏎···`
input,
client,
mockDateFormat,
Expand Down Expand Up @@ -1212,7 +1212,7 @@ test('create report for data set contains null field value', async () => {

test('create report for data set with metadata fields', async () => {
const metadataFields = { _index: 'nameofindex', _id: 'someid' };
let hits = [
const hits = [
hit(
{
category: 'c1',
Expand Down Expand Up @@ -1493,8 +1493,8 @@ function mockOpenSearchClient(
};
case 'clearScroll':
return null;
default:
fail('Fail due to unexpected function call on client', endpoint);
default:

Check failure on line 1496 in server/routes/utils/__tests__/savedSearchReportHelper.test.ts

View workflow job for this annotation

GitHub Actions / Lint

Delete `··`
throw new Error(`Fail due to unexpected function call on client: ${endpoint}`);

Check failure on line 1497 in server/routes/utils/__tests__/savedSearchReportHelper.test.ts

View workflow job for this annotation

GitHub Actions / Lint

Replace `············throw·new·Error(`Fail·due·to·unexpected·function·call·on·client:·${endpoint}`` with `··········throw·new·Error(⏎············`Fail·due·to·unexpected·function·call·on·client:·${endpoint}`⏎··········`
}
});
return client;
Expand Down Expand Up @@ -1572,9 +1572,9 @@ function mockIndexSettings() {
`);
}

function hit(source_kv: any, fields_kv = {}) {
function hit(sourceKv: any, fieldsKv = {}) {

Check warning on line 1575 in server/routes/utils/__tests__/savedSearchReportHelper.test.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
return {
_source: source_kv,
fields: fields_kv,
_source: sourceKv,
fields: fieldsKv,
};
}
Empty file added server/routes/utils/test
Empty file.

0 comments on commit bf612d0

Please sign in to comment.