mirror of
https://github.com/Kaelio/ktx.git
synced 2026-06-25 08:48:08 +02:00
fix(cli): auto-install runtime during setup (#116)
* fix(cli): auto-install runtime during setup * test: align docs smoke with readme
This commit is contained in:
parent
42b688e934
commit
a72fca2b32
11 changed files with 131 additions and 23 deletions
|
|
@ -11,7 +11,7 @@ import {
|
|||
} from '@ktx/context/ingest';
|
||||
import { initKtxProject, ktxLocalStateDbPath, loadKtxProject } from '@ktx/context/project';
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
|
||||
import { type KtxIngestArgs, runKtxIngest } from './ingest.js';
|
||||
import { type KtxIngestArgs, type KtxIngestDeps, runKtxIngest } from './ingest.js';
|
||||
import type { KtxCliLocalIngestAdaptersOptions } from './local-adapters.js';
|
||||
import {
|
||||
CliLookerSlWritingAgentRunner,
|
||||
|
|
@ -1108,6 +1108,7 @@ describe('runKtxIngest', () => {
|
|||
completedLocalBundleRun(input, input.jobId ?? 'local-job-1'),
|
||||
);
|
||||
const io = makeIo();
|
||||
const runtimeIo = makeIo({ isTTY: true });
|
||||
|
||||
await expect(
|
||||
runKtxIngest(
|
||||
|
|
@ -1125,6 +1126,9 @@ describe('runKtxIngest', () => {
|
|||
createAdapters,
|
||||
runLocalIngest: runLocal,
|
||||
jobIdFactory: () => 'local-job-1',
|
||||
runtimeIo: runtimeIo.io,
|
||||
} as KtxIngestDeps & {
|
||||
runtimeIo: typeof runtimeIo.io;
|
||||
},
|
||||
),
|
||||
).resolves.toBe(0);
|
||||
|
|
@ -1133,7 +1137,7 @@ describe('runKtxIngest', () => {
|
|||
cliVersion: '0.2.0',
|
||||
projectDir,
|
||||
installPolicy: 'auto',
|
||||
io: io.io,
|
||||
io: runtimeIo.io,
|
||||
};
|
||||
expect(createAdapters).toHaveBeenCalledWith(
|
||||
expect.objectContaining({ projectDir }),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue