MCPcopy Index your code
hub / github.com/devcontainers/cli / log

Function log

src/spec-node/featuresCLI/testCommandImpl.ts:28–40  ·  view source on GitHub ↗
(msg: string, options?: { omitPrefix?: boolean; prefix?: string; info?: boolean; error?: boolean })

Source from the content-addressed store, hash-verified

26type TestResult = { testName: string; result: boolean };
27
28function log(msg: string, options?: { omitPrefix?: boolean; prefix?: string; info?: boolean; error?: boolean }) {
29
30 const prefix = options?.prefix || '> ';
31 const output = `${options?.omitPrefix ? '' : `${prefix} `}${msg}\n`;
32
33 if (options?.error) {
34 process.stdout.write(chalk.red(output));
35 } else if (options?.info) {
36 process.stdout.write(chalk.bold.blue(output));
37 } else {
38 process.stdout.write(chalk.blue(output));
39 }
40}
41
42export async function doFeaturesTestCommand(args: FeaturesTestCommandInput): Promise<number> {
43 const { pkg, globalScenariosOnly, features, collectionFolder, cliHost } = args;

Callers 10

consumeFunction · 0.85
failFunction · 0.85
cleanupFunction · 0.85
runGlobalFeatureTestsFunction · 0.85
runDuplicateTestFunction · 0.85
runFeatureTestsFunction · 0.85
doScenarioFunction · 0.85
analyzeTestResultsFunction · 0.85

Calls 1

writeMethod · 0.65

Tested by

no test coverage detected