-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
…ge names See: #310
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Used for E2E tests. | ||
l3packages | ||
lipsum | ||
shellesc | ||
xparse |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
@@ -1,4 +1,4 @@ | ||||||||||
import { afterAll, beforeAll, expect, it, vi } from 'vitest'; | ||||||||||
import { afterEach, beforeEach, describe, expect, it, test, vi } from 'vitest'; | ||||||||||
|
||||||||||
import shellesc from '@setup-texlive-action/fixtures/ctan-api-pkg-shellesc.json'; | ||||||||||
import stderr2008 from '@setup-texlive-action/fixtures/tlmgr-install.2008.stderr'; | ||||||||||
|
@@ -12,18 +12,16 @@ import { install } from '#texlive/tlmgr/actions/install'; | |||||||||
import { TlmgrInternals, set } from '#texlive/tlmgr/internals'; | ||||||||||
import type { Version } from '#texlive/version'; | ||||||||||
|
||||||||||
const toTL: Record<string, string | undefined> = {}; | ||||||||||
vi.mock('node:timers/promises'); | ||||||||||
vi.mock('@setup-texlive-action/data/package-names.json', () => ({ | ||||||||||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
teatimeguest
Author
Owner
|
"exports": { | |
".": "./src/index.ts", | |
"./*": "./data/*" | |
}, |
This makes the module to be resolved as follows:
"@setup-texlive-action/data/package-names.json"
// \________________________/ \________________/
// ┌────┘ ┌───────┘
// ▼ Package dir ▼ Exported subpath
// /‾‾‾‾‾‾‾‾‾‾‾‾‾\ /‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾\
==> "./packages/data/data/package-names.json"
Nevertheless, it is indeed confusing to have nested directories with the same name... (besides, module resolution in Node.js + TypeScript is horribly complicated)
This comment has been minimized.
This comment has been minimized.
Sorry, something went wrong.
It seems this doesn't match
packages/data/data/package-names.json
(note the nesteddata
sub-directories), the relative path of the realpackage-names.json
.