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

Test to see if build goes green 2 #238

Closed
wants to merge 400 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
400 commits
Select commit Hold shift + click to select a range
4d00b7c
workflowx234asd
rinrub Jun 19, 2024
d3a0564
update workflows 123123
rinrub Jun 19, 2024
7627d44
update act on tests
rinrub Jun 19, 2024
0cfef35
update setupTest to ts file
rinrub Jun 20, 2024
8cac8f2
Added handling of default date
andreasnp Jun 20, 2024
847019d
Removed comments and fixed eslint warnings
andreasnp Jun 20, 2024
00d6d75
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Jun 20, 2024
6d0d93a
Updated package.lock
andreasnp Jun 20, 2024
bbf2135
Merge pull request #188 from helsenorge/andreasn/core30
andreasnp Jun 20, 2024
9b39cd7
Fixed 1 test and skipped 1 test temprarily
andreasnp Jun 20, 2024
c16b1d3
Merge pull request #194 from helsenorge/andreasn/core30
andreasnp Jun 20, 2024
59177ec
Implemented datepicker in date-year-input
andreasnp Jun 21, 2024
115788c
Adjusted width on year input field
andreasnp Jun 21, 2024
bef3992
add vitests
rinrub Jun 21, 2024
874e0e0
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Jun 21, 2024
fe7e7e7
upgrade core
rinrub Jun 21, 2024
526aef8
added vitest and fixed failing tests
rinrub Jun 23, 2024
6b171c1
Merge pull request #196 from helsenorge/rubenr/add-vitest
ruberino Jun 23, 2024
3130305
Replaced register with controller and added validation for valid year
andreasnp Jun 24, 2024
0b655ed
Created validation for min and max year
andreasnp Jun 24, 2024
c493be5
Replaced mock constants in date time with actual values
andreasnp Jun 24, 2024
9a45067
Removed commented code
andreasnp Jun 24, 2024
bb82b1b
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Jun 24, 2024
f2d12c6
removed packages
rinrub Jun 24, 2024
612e3aa
fix test setup ts
rinrub Jun 24, 2024
599437e
update tests and testimports
rinrub Jun 24, 2024
4c228f5
added tests
rinrub Jun 24, 2024
d9d58ec
new npm scropt
rinrub Jun 24, 2024
3f9ccd6
tests
rinrub Jun 24, 2024
94ca2cf
remove file
rinrub Jun 24, 2024
eafc6a6
small changes to validation-summarty
rinrub Jun 24, 2024
8fe8dfa
fix showing of text fields in errorSummary
rinrub Jun 25, 2024
f33777f
Use datepicker in yearmonth, converted components to functional
andreasnp Jun 26, 2024
c91a3e9
add tests to validation summary
rinrub Jun 26, 2024
cf21244
small changes to validation-summarty
rinrub Jun 24, 2024
3fdc013
fix showing of text fields in errorSummary
rinrub Jun 25, 2024
8bf2a8a
add tests to validation summary
rinrub Jun 26, 2024
678970e
Added handleChange function for both inputs in year-month
andreasnp Jun 26, 2024
b62f2b6
Added validation on date field
andreasnp Jun 26, 2024
eec8cca
Added empty option in year-month select
andreasnp Jun 27, 2024
5c43138
Changed number type to string type on year and month states
andreasnp Jun 27, 2024
a2f0353
Fixed logic in handling of default month value
andreasnp Jun 27, 2024
8cc1793
added tests and new defaultFormValues
rinrub Jun 28, 2024
ec0fa38
More handling of month default value
andreasnp Jun 28, 2024
9406c9c
add tests
rinrub Jun 28, 2024
c11f943
finished up tests for default values
rinrub Jun 28, 2024
28e64f0
bumå
rinrub Jun 28, 2024
1ac0c72
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Jun 28, 2024
bfce184
Merge pull request #199 from helsenorge/rubenr/default-values
ruberino Jun 28, 2024
523e6bc
changelog and version
rinrub Jun 28, 2024
edeff37
fixed tyoes for lib byuld
rinrub Jun 28, 2024
27daf8c
Converted date-day to functional and implemented datepicker
andreasnp Jul 1, 2024
b8ff823
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Jul 1, 2024
08fdcfd
Merge remote-tracking branch 'origin/master' into rubenr/react-hook-form
rinrub Jul 1, 2024
0f93803
Added handling of date default values
andreasnp Jul 1, 2024
84ba376
Updated logic for handleDateChange
andreasnp Jul 1, 2024
28380cb
Merge remote-tracking branch 'origin/master' into rubenr/react-hook-form
rinrub Jul 1, 2024
e307c4f
Added default date const in date-day-input
andreasnp Jul 2, 2024
19d2d95
Added return type on function
andreasnp Jul 2, 2024
c37c80e
Merge pull request #195 from helsenorge/andreasn/date-year
andreasnp Jul 2, 2024
f842bf6
Made tests for date day
andreasnp Jul 3, 2024
99dff04
Created more tests in date-day
andreasnp Jul 3, 2024
aef3b1b
More date-day tests, fixed parse error in get date extension funcs
andreasnp Jul 8, 2024
fdd250c
Removed unused imports
andreasnp Jul 8, 2024
d5b2ecd
Renamed test file
andreasnp Jul 8, 2024
0c16438
Renamed questionnaire json files for date-day tests
andreasnp Jul 8, 2024
bca6061
Moved questionnaire json test files for date-day to its own folder
andreasnp Jul 8, 2024
ef4aca5
Created tests for date-time
andreasnp Jul 8, 2024
a7ca47b
update vite and vitest
rinrub Jul 29, 2024
6fdf902
added conditional placeholder
rinrub Jul 30, 2024
1d43a39
add mapstatetoprops to common functions
rinrub Jul 31, 2024
c6ca397
remove connect stuff
rinrub Jul 31, 2024
096e515
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Jul 31, 2024
778e73a
fixed tests and added enable to component props
rinrub Aug 1, 2024
a9894d5
Merge pull request #203 from helsenorge/rubenr/use-redux-hooks
ruberino Aug 1, 2024
4a08963
move answer to hook
rinrub Aug 1, 2024
4db07d4
move enable to each component
rinrub Aug 1, 2024
27837f1
remove functions to get components from hoc
rinrub Aug 5, 2024
5b53a65
delete button and repeat button
rinrub Aug 5, 2024
5548cb1
moving towards removing hoc
rinrub Aug 5, 2024
70933cf
split group component
rinrub Aug 6, 2024
131bcb5
Added more date-time tests
andreasnp Aug 6, 2024
5c80dab
update components
rinrub Aug 6, 2024
183bdf7
new common children render
rinrub Aug 6, 2024
d074b96
Added more tests for date time
andreasnp Aug 7, 2024
5c99d11
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 7, 2024
555b741
Merge pull request #204 from helsenorge/andreasn/date-year
andreasnp Aug 7, 2024
b1df26c
tests
rinrub Aug 7, 2024
650ad8e
fix open-choice
rinrub Aug 7, 2024
1274f4e
quantity uten unit
rinrub Aug 7, 2024
6695df3
tests
rinrub Aug 7, 2024
1a01c53
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Aug 7, 2024
e25d052
merge
rinrub Aug 7, 2024
f854b80
fix date
rinrub Aug 7, 2024
3405dfc
Merge pull request #205 from helsenorge/rubenr/remove-hocs
ruberino Aug 7, 2024
5703a19
Removed skip from date tests and fixed minmax bug
andreasnp Aug 8, 2024
13557bb
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 8, 2024
3691114
Updated date components after global state changes
andreasnp Aug 8, 2024
c89c405
Simplified method
andreasnp Aug 8, 2024
b43c630
Created one more date-time test
andreasnp Aug 8, 2024
019353c
Added test files for date year and date month
andreasnp Aug 9, 2024
5c73192
Created tests for date year
andreasnp Aug 9, 2024
9c52f89
remove all connects and add more external functions to context
rinrub Aug 8, 2024
b1e07d1
change the way items are rendered
rinrub Aug 9, 2024
ccb18cf
remove unused
rinrub Aug 9, 2024
96c35d2
removed unused code and moved the props
rinrub Aug 9, 2024
ed6b47b
attachemnt context, rename props and components
rinrub Aug 9, 2024
3b67fa2
move scoring to hook
rinrub Aug 9, 2024
4b82000
move more props to context
rinrub Aug 9, 2024
0976980
Created more date month tests
andreasnp Aug 12, 2024
8a09ce0
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 12, 2024
ff16ed2
Created the rest of the date month tests
andreasnp Aug 12, 2024
386e157
Merge pull request #208 from helsenorge/andreasn/date-year
andreasnp Aug 12, 2024
f567863
tests
rinrub Aug 12, 2024
f54579e
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Aug 12, 2024
29ee975
refactor scoring
rinrub Aug 12, 2024
f7789a7
move onAnswerChange to hook
rinrub Aug 13, 2024
c0ac625
removed failing test
rinrub Aug 13, 2024
2add6de
upgrade fhirpath
rinrub Aug 13, 2024
360d22e
Merge pull request #209 from helsenorge/rubenr/upgrade-fhirpath
ruberino Aug 13, 2024
644a045
upgrade marked, updated code
rinrub Aug 13, 2024
010f971
Converted time component to functional component
andreasnp Aug 13, 2024
511763e
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 13, 2024
3c8548b
Made time work with react-hook-form, removed types/marked
andreasnp Aug 14, 2024
d8b45e5
Added error texts to time component
andreasnp Aug 14, 2024
5eb1efd
Added label and help element to Time component
andreasnp Aug 14, 2024
67805c1
Updated logic in validation for min/max hours and minutes
andreasnp Aug 14, 2024
5b425aa
Created tests for pdf in time.tsx
andreasnp Aug 14, 2024
885b491
custom help button test
rinrub Aug 14, 2024
2b34343
attachment tests
rinrub Aug 14, 2024
aa5d789
attachment tests
rinrub Aug 15, 2024
17c9a02
date-time tests
rinrub Aug 16, 2024
dbec4c5
date-time custom error allways showing up
rinrub Aug 19, 2024
37bbafa
datetim and test
rinrub Aug 19, 2024
51f28aa
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Aug 19, 2024
2785f02
unskip teste
rinrub Aug 19, 2024
6c1b257
Merge pull request #212 from helsenorge/rubenr/date-and-datetime-tests
ruberino Aug 19, 2024
68f3ead
core 32 and react 18
rinrub Aug 19, 2024
5ff5573
changes
rinrub Aug 19, 2024
a9049a6
remove lock
rinrub Aug 19, 2024
7072596
added lick
rinrub Aug 19, 2024
90ec5aa
optional dep
rinrub Aug 19, 2024
2af98ab
optional dep more
rinrub Aug 19, 2024
b7d0e61
global test
rinrub Aug 19, 2024
fabfbad
last try global this
rinrub Aug 19, 2024
4daabea
global this
rinrub Aug 19, 2024
6903f57
Created more validation and test for Time
andreasnp Aug 20, 2024
a5d0d08
Date day: updated props, handling that date can be undefined
andreasnp Aug 20, 2024
637a2bd
year month: updated props, added styling
andreasnp Aug 20, 2024
341aed0
Updated props in date-year and date, updated date util functions
andreasnp Aug 20, 2024
f81414a
Made select field wider in month, added comments from QA
andreasnp Aug 20, 2024
a2d7dd7
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 20, 2024
ca4bc12
tests
rinrub Aug 20, 2024
5a4ce3c
teste2
rinrub Aug 20, 2024
c36babb
ts warns ignore
rinrub Aug 21, 2024
dc2de2e
fix error with onStepChange
rinrub Aug 22, 2024
dbc4880
fix failing prop in hn-skjema
rinrub Aug 22, 2024
df08be6
dep array
rinrub Aug 22, 2024
56ae15f
changes
rinrub Aug 22, 2024
aa75445
Removed state for hour and minute, now gets value from answer
andreasnp Aug 22, 2024
eaf7a06
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 22, 2024
c5fc61f
Merge pull request #215 from helsenorge/andreasn/date-year
andreasnp Aug 22, 2024
08e53f0
Update import of ReferoContainer
andreasnp Aug 23, 2024
7de7b91
Fixed logic in getErrorText functions
andreasnp Aug 23, 2024
ae12dd2
tests
rinrub Aug 22, 2024
0cd43bc
update tests
rinrub Aug 23, 2024
5dd5a7b
new release
rinrub Aug 23, 2024
7a601c4
update v
rinrub Aug 23, 2024
37c8ab1
fix types in build package.json
rinrub Aug 23, 2024
ed4c6e9
beta23
rinrub Aug 23, 2024
ac2da0b
beta24
rinrub Aug 23, 2024
6d4d78f
Merge remote-tracking branch 'origin/master' into release/beta-25
rinrub Aug 26, 2024
c417603
versioon
rinrub Aug 26, 2024
c3d5a50
added prepare
rinrub Aug 26, 2024
206f468
Merge pull request #221 from helsenorge/release/beta-25
ruberino Aug 26, 2024
9dfedf2
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rub…
rinrub Aug 26, 2024
cf94a7c
Added the rest of the tests for Time
andreasnp Aug 26, 2024
fc7a612
update lock
rinrub Aug 27, 2024
2cdf179
merge from feature
rinrub Aug 27, 2024
6b52f07
Adjusted types and names in extractTime functions
andreasnp Aug 27, 2024
c1ce17c
fix tests
rinrub Aug 27, 2024
ac7df39
fix build warns
rinrub Aug 27, 2024
e9b17f0
src in types
rinrub Aug 27, 2024
92a97aa
version
rinrub Aug 27, 2024
59dc567
Fixed tests that failed in date-month
andreasnp Aug 27, 2024
f9dbe6d
remove peer deps
rinrub Aug 27, 2024
a93b26f
add fix for css
rinrub Aug 27, 2024
c7dc0c0
update package.json
rinrub Aug 28, 2024
5a791a6
update package.json
rinrub Aug 28, 2024
8b51e5a
Merge pull request #213 from helsenorge/rubenr/core32
ruberino Aug 28, 2024
fa84346
Fix of skipped date tests
andreasnp Aug 28, 2024
4235b68
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Aug 28, 2024
41d13a9
Fixed tests after react 18 upgrade
andreasnp Aug 28, 2024
1d5ccbe
add deprication to store prop
rinrub Aug 28, 2024
98f2c76
remove resources as props on delete button
rinrub Aug 28, 2024
9663eb3
change to unique key
rinrub Aug 28, 2024
ae21f4c
Installed new designsystem and datepicker with bugfix
andreasnp Aug 28, 2024
a1b7032
add styling for buttons, label and groups
rinrub Sep 3, 2024
b057a56
fix resources on repeat-button, ts prettify on form.ts
rinrub Sep 3, 2024
2f2bf6d
only run scoring when there is scoring-extensions present
rinrub Sep 3, 2024
38f6875
moved reset to useeffect, removed unused in tests
rinrub Sep 4, 2024
4e9291f
fix labels in tests
rinrub Sep 4, 2024
d21a858
added resources to optional text, and test
rinrub Sep 4, 2024
c00d2c5
remove unused, update version
rinrub Sep 4, 2024
8ea4fd4
Merge remote-tracking branch 'origin/master' into rubenr/react-hook-form
rinrub Sep 9, 2024
fba6966
install
rinrub Sep 9, 2024
b98b3fb
readded peerdeps
rinrub Sep 9, 2024
28b0fcb
config
rinrub Sep 9, 2024
d07079c
readded peerdeps
rinrub Sep 9, 2024
3bf7a04
config
rinrub Sep 9, 2024
badd305
styling for sublabel and fixing markdown styles
rinrub Sep 9, 2024
67b4e7a
date-day now expect and exports correct date format
andreasnp Sep 10, 2024
81a2986
remove layout hook, remove control from controller
rinrub Sep 10, 2024
dcba799
remove controller
rinrub Sep 10, 2024
706204c
remove unused, use item.linkId
rinrub Sep 11, 2024
4754cce
moved validation rules to common file
rinrub Sep 11, 2024
f674a0f
update tests with new rules
rinrub Sep 11, 2024
947bd11
fix tests, remove debounce causing problems with onchange
ruberino Sep 12, 2024
7551f2f
Implemented skipped tests
andreasnp Sep 12, 2024
b7f2737
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Sep 13, 2024
551e485
add padding bottom error-summary
ruberino Sep 13, 2024
9cf58cb
Fixed date-day test in defaultFormValues test file
andreasnp Sep 13, 2024
19edee8
Fixed copy-from tests
andreasnp Sep 14, 2024
ab73bc6
Added Time tests in defaultFormValues file
andreasnp Sep 16, 2024
aaf697e
Created onChange tests for Time and Date
andreasnp Sep 16, 2024
c62c1f0
Merge branch 'rubenr/react-hook-form' of https://github.com/helsenorg…
andreasnp Sep 16, 2024
2bb7a84
Fixed onChange tests for dateDay
andreasnp Sep 16, 2024
906937d
Fixed onChange tests for date-time
andreasnp Sep 16, 2024
69c21e8
Temporarily skipped test that fails
andreasnp Sep 16, 2024
9a335c3
Merge pull request #231 from helsenorge/andreasn/date-year
andreasnp Sep 16, 2024
40d7a3f
small fixes
ruberino Sep 17, 2024
ce58124
ts errors
ruberino Sep 17, 2024
7de9f55
remove debug from date-time
ruberino Sep 17, 2024
99b5dfa
removed unused
ruberino Sep 17, 2024
45fec3b
updated to ci in github actions
ruberino Sep 17, 2024
22cdc0d
captial letter git issue
ruberino Sep 17, 2024
31cbc47
remove only
ruberino Sep 17, 2024
e7ae226
test fix
ruberino Sep 17, 2024
e2b183f
Fixed 2 tests in time, added date-month tests in defaultFormValues
andreasnp Sep 17, 2024
b3c1253
Merge pull request #234 from helsenorge/andreasn/date-year
andreasnp Sep 17, 2024
16c93d5
Fix of date-time tests that fails in github build
andreasnp Sep 17, 2024
fd96f71
Merge pull request #235 from helsenorge/andreasn/date-year
andreasnp Sep 17, 2024
b3b73a6
Attempt to fix date tests that fails in github build
andreasnp Sep 18, 2024
5edf097
Merge branch 'release-16.0.0-beta.29' of https://github.com/helsenorg…
andreasnp Sep 18, 2024
62d75ef
Merge pull request #237 from helsenorge/andreasn/date-year
andreasnp Sep 18, 2024
c298441
Removed mockdate package, mock timezone manually
andreasnp Sep 18, 2024
74bfe8f
Merge pull request #239 from helsenorge/andreasn/date-year
andreasnp Sep 18, 2024
d37a0c2
update redux react-redux and redux-thunk
ruberino Sep 18, 2024
76398fc
Merge remote-tracking branch 'origin/rubenr/react-hook-form' into rel…
ruberino Sep 18, 2024
f24e607
Merge branch 'release-16.0.0-beta.29' of https://github.com/helsenorg…
ruberino Sep 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .browserslistrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
defaults
3 changes: 2 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
node_modules/*
config/*
**/types/*
*.d.ts
*.d.ts
lib/*
38 changes: 38 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"parser": "@typescript-eslint/parser",
"extends": ["eslint:recommended", "plugin:@typescript-eslint/eslint-recommended", "prettier", "plugin:@typescript-eslint/recommended"],
"parserOptions": {
"ecmaVersion": 2020,
"sourceType": "module"
},
"plugins": ["react", "import", "testing-library", "jest-dom", "@typescript-eslint"],
"globals": {
"React": true,
"JSX": true
},
"rules": {
"@typescript-eslint/ban-types": "warn",
"@typescript-eslint/explicit-function-return-type": "warn",
"@typescript-eslint/no-empty-interface": "warn",
"@typescript-eslint/no-explicit-any": "error",
"react/jsx-no-literals": "error",
"react/display-name": "warn",
"no-console": "error",
"no-debugger": "error",
"react/react-in-jsx-scope": 0,
"@typescript-eslint/no-use-before-define": 0,
"@typescript-eslint/no-inferrable-types": 0
},
"settings": {
"react": {
"version": "detect"
}
},
"overrides": [
{
// 3) Now we enable eslint-plugin-testing-library rules or preset only for matching files!
"files": ["**/__tests__/**/*.[jt]s?(x)", "**/?(*.)+(spec|test).[jt]s?(x)"],
"extends": ["plugin:testing-library/react"]
}
]
}
134 changes: 0 additions & 134 deletions .eslintrc.js

This file was deleted.

26 changes: 13 additions & 13 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@ name: Build

on:
push:
branches: [ master ]
branches: [master]
pull_request:
branches: [ master ]
branches: [master]
workflow_dispatch:

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
node-version: [18.x, 20.x]
# See supported Node.js release, schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm install
- run: npm run build:js --if-present
- run: npm test
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- run: npm ci
- run: npm run build:js --if-present
- run: npm test
5 changes: 3 additions & 2 deletions .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,12 @@ on:
jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- run: npm ci
- run: npm test

Expand All @@ -25,7 +26,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm run prepare
Expand Down
31 changes: 22 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,41 @@ on:
release:
types: [released]

workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- name: Checkout repo
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 18
- run: npm ci
- run: npm test
node-version: 20
cache: "npm"

- name: Clean cache
run: npm cache clean --force

- name: Install dependencies
run: npm ci

- name: Test
run: npm test

publish-npm:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm run prepare
- run: npm run build:lib
- run: cd ./lib && npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.PUBLISH_HELSENORGE_PACKAGES_TO_NPMJS}}
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,9 @@ lib/
.jest-cache/
coverage/
test-report.xml
.npmrc
sonar-report.xml
.npmrc
vite.config.ts.timestamp*
vitest.config.ts.timestamp*

html/
8 changes: 7 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
SkjemautfyllerEnums.ts
SkjemautfyllerEntities.d.ts
types/fhir.ts
types/fhir.ts
node_modules
.prettierrc
.eslintrc
.gitignore
lib
config
8 changes: 8 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"endOfLine": "auto",
"arrowParens": "avoid",
"proseWrap": "always",
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 140
}
8 changes: 0 additions & 8 deletions .prettierrc.js

This file was deleted.

3 changes: 2 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"recommendations": [
// Extension identifier format: ${publisher}.${name}. Example: vscode.csharp
"esbenp.prettier-vscode",
"dbaeumer.vscode-eslint"
"dbaeumer.vscode-eslint",
"rvest.vs-code-prettier-eslint"
]
}
31 changes: 7 additions & 24 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,32 +1,15 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"type": "chrome",
"request": "launch",
"name": "Jest All",
"program": "${workspaceFolder}/node_modules/.bin/jest",

"args": ["--runInBand", "--config", "${workspaceRoot}/node_modules/@helsenorge/core-build/lib/jest.config.js"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true,
"windows": {
"program": "${workspaceFolder}/node_modules/jest/bin/jest"
}
},
{
"type": "node",
"request": "launch",
"name": "Jest Current File",
"program": "${workspaceFolder}/node_modules/.bin/jest",
"args": ["${fileBasenameNoExtension}", "--config", "${workspaceRoot}/node_modules/@helsenorge/core-build/lib/jest.config.js"],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"disableOptimisticBPs": true,
"windows": {
"program": "${workspaceFolder}/node_modules/jest/bin/jest"
}
"name": "Launch Chrome against localhost",
"url": "http://localhost:5173",
"webRoot": "${workspaceFolder}"
}
]
}
Loading
Loading