Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Polish scale #173

Draft
wants to merge 6 commits into
base: develop
Choose a base branch
from
Draft

Conversation

Agilulfo
Copy link
Contributor

@Agilulfo Agilulfo commented Sep 17, 2024

Initial draft changes to add the polish scale a.k.a. kurtyka scale
implements: #172

TODO:

  • Add polish scale to csv file
  • Update Readme
  • Add polish scale implementation : src/scales/polish.ts
  • reference scale in : src/scales/index.ts
  • Add tests
  • Generate json file
  • Document how to add a scale

Copy link

github-actions bot commented Sep 17, 2024

Coverage report

Caution

Coverage does not meet threshold
Statements coverage not met for global: expected <=999999 not covered statements, but got 39

St.
Category Percentage Covered / Total
🟢 Statements
95.12% (+7.62% 🔼)
39/41
🟢 Branches
83.33% (+15.79% 🔼)
5/6
🟢 Functions
90.91% (+11.04% 🔼)
10/11
🟢 Lines
94.59% (+7.91% 🔼)
35/37

Test suite run failed

Failed tests: 0/10. Failed suites: 16/18.
  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


  ● Test suite failed to run

    src/scales/polish.ts:13:3 - error TS2322: Type '{ displayName: string; name: "polish"; offset: number; allowableConversionType: ("yds" | "ewbank" | "saxon")[]; isType: (grade: string) => boolean; getScore: (grade: string) => number | Tuple; getGrade: (score: number | Tuple) => string; getGradeBand: (grade: string) => GradeBandTypes; }' is not assignable to type 'GradeScale'.
      Object literal may only specify known properties, and 'allowableConversionType' does not exist in type 'GradeScale'.

    13   allowableConversionType: [GradeScales.YDS, GradeScales.EWBANK, GradeScales.SAXON],
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Report generated by 🧪jest coverage report action from becb958

src/data/routes.csv Outdated Show resolved Hide resolved
@Agilulfo Agilulfo force-pushed the Add-polish-scale branch 2 times, most recently from d3a2cf4 to e89acb7 Compare September 17, 2024 13:10
@musoke
Copy link
Collaborator

musoke commented Sep 18, 2024

This looks like you're on the right path! Let us know if you need help.

@Agilulfo
Copy link
Contributor Author

@musoke thank you!
It might take me a while since I'm picking typescript as I go on my spare time.
Will let you know when it is ready for review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants