@@ -348,3 +348,57 @@ jobs:
348348 run : |
349349 npm --workspace=@examples-type-portability/${{ matrix.example.name }} pkg set type=module
350350 yarn workspace @examples-type-portability/${{ matrix.example.name }} run test --module ESNext --moduleResolution Node10 --preserveSymLinks --verbatimModuleSyntax false
351+
352+ test-types-native-preview :
353+ name : ' Test Types: TypeScript Native Preview'
354+ needs : [build]
355+ runs-on : ubuntu-latest
356+ continue-on-error : true
357+ strategy :
358+ matrix :
359+ node : ['24.x']
360+ steps :
361+ - name : Checkout repo
362+ uses : actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
363+
364+ - name : Use node ${{ matrix.node }}
365+ uses : actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5
366+ with :
367+ node-version : ${{ matrix.node }}
368+ cache : ' yarn'
369+
370+ - name : Install deps
371+ run : yarn install
372+
373+ - name : Install TypeScript Native Preview
374+ run : yarn add @typescript/native-preview
375+
376+ - uses : actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4
377+ with :
378+ name : package
379+ path : packages/toolkit
380+
381+ - name : Install build artifact
382+ run : yarn add ./package.tgz
383+
384+ - name : Show installed RTK versions
385+ run : yarn info @reduxjs/toolkit
386+
387+ - name : Erase path aliases
388+ run : sed -i -e /@remap-prod-remove-line/d ./tsconfig.base.json
389+
390+ - name : Test types with tsgo
391+ env :
392+ TEST_DIST : true
393+ run : |
394+ yarn tsgo --version
395+ yarn tsgo -p tsconfig.test.json --noEmit
396+
397+ - name : Install build artifact for type-portability example
398+ run : yarn workspace @examples-type-portability/bundler add $(pwd)/package.tgz
399+
400+ - name : Install TypeScript Native Preview for type-portability example
401+ run : yarn workspace @examples-type-portability/bundler add -D @typescript/native-preview
402+
403+ - name : Test type portability with tsgo (bundler example)
404+ run : yarn workspace @examples-type-portability/bundler exec tsgo --noEmit
0 commit comments