Skip to content

Commit

Permalink
fix: more adjustments and fixes (#92)
Browse files Browse the repository at this point in the history
  • Loading branch information
holtgrewe authored Feb 5, 2024
1 parent 39150cc commit 1f2f8b2
Show file tree
Hide file tree
Showing 5 changed files with 3,641 additions and 3,518 deletions.
8 changes: 4 additions & 4 deletions src/api/annonars/types.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { JsonValue } from '@protobuf-ts/runtime'

import { Record as ClinvarSeqvarRecord } from '../../pbs/annonars/clinvar/minimal'
import { Record as ClinvarStrucvarRecord } from '../../pbs/annonars/clinvar/sv'
import { ResponseRecord as ClinvarStrucvarResponseRecord } from '../../pbs/annonars/clinvar/sv'
import { Record as UcscConservationRecord } from '../../pbs/annonars/cons/base'
import { Record as DbsnpRecord } from '../../pbs/annonars/dbsnp/base'
import { Record as GeneInfoRecord } from '../../pbs/annonars/genes/base'
Expand All @@ -15,14 +15,14 @@ import { Record as HelixmtdbRecord } from '../../pbs/annonars/helixmtdb/base'
* Interface for Clinvar Strucvars query response as returned by
*/
export interface ClinvarSvQueryResponse$Api {
records: ClinvarStrucvarRecord[]
records: JsonValue[]
}

/**
* Interface for Clinvar Strucvars query result.
*/
export interface ClinvarSvQueryResponse {
records: ClinvarStrucvarRecord[]
records: ClinvarStrucvarResponseRecord[]
}

/**
Expand All @@ -31,7 +31,7 @@ export interface ClinvarSvQueryResponse {
class ClinvarSvQueryResponse$Type {
fromJson(apiResponse: ClinvarSvQueryResponse$Api): ClinvarSvQueryResponse {
return {
records: apiResponse.records
records: apiResponse.records.map((value) => ClinvarStrucvarResponseRecord.fromJson(value))
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const strucvarInfo: Strucvar = {
}
const clinvarSvRecords = JSON.parse(
fs.readFileSync(path.resolve(__dirname, './fixture.clinvarSvRecords.BRCA1.json'), 'utf8')
).map((record: JsonValue) => ClinvarSvRecord.fromJson(record))
).records.map((record: JsonValue) => ClinvarSvRecord.fromJson(record))

describe.concurrent('StrucvarClinvarCard.vue', async () => {
it('renders the info', async () => {
Expand Down
Loading

0 comments on commit 1f2f8b2

Please sign in to comment.