chore: updating to latest version with some changes
Signed-off-by: blam <ben@blam.sh>
This commit is contained in:
@@ -134,7 +134,7 @@ async function getProjectConfig(targetPath, displayName) {
|
||||
'\\.(js|jsx|ts|tsx|mjs|cjs)$': [
|
||||
'@swc/jest',
|
||||
{
|
||||
enableSourceMaps: envOptions.enableSourceMaps || envOptions.nextTests,
|
||||
sourceMaps: false, // envOptions.enableSourceMaps || envOptions.nextTests,
|
||||
},
|
||||
],
|
||||
// '^.+\\.(t|j)sx?$': '@swc/jest',
|
||||
|
||||
+3
-3
@@ -17,12 +17,12 @@ const executeShellCommand = jest.fn();
|
||||
const commandExists = jest.fn();
|
||||
const fetchContents = jest.fn();
|
||||
|
||||
jest.mock('@backstage/plugin-scaffolder-backend', () => ({
|
||||
...jest.requireActual('@backstage/plugin-scaffolder-backend'),
|
||||
jest.doMock('@backstage/plugin-scaffolder-backend', () => ({
|
||||
...require('@backstage/plugin-scaffolder-backend'),
|
||||
fetchContents,
|
||||
executeShellCommand,
|
||||
}));
|
||||
jest.mock('command-exists', () => commandExists);
|
||||
jest.doMock('command-exists', () => commandExists);
|
||||
|
||||
import {
|
||||
getVoidLogger,
|
||||
|
||||
+3
-4
@@ -17,15 +17,14 @@
|
||||
const executeShellCommand = jest.fn();
|
||||
const commandExists = jest.fn();
|
||||
|
||||
jest.mock('@backstage/plugin-scaffolder-backend', () => ({
|
||||
jest.doMock('@backstage/plugin-scaffolder-backend', () => ({
|
||||
executeShellCommand,
|
||||
}));
|
||||
jest.mock('command-exists', () => commandExists);
|
||||
jest.mock('fs-extra');
|
||||
jest.doMock('command-exists', () => commandExists);
|
||||
|
||||
import { ContainerRunner } from '@backstage/backend-common';
|
||||
import fs from 'fs-extra';
|
||||
|
||||
import mockfs from 'mock-fs';
|
||||
import path from 'path';
|
||||
import { PassThrough } from 'stream';
|
||||
|
||||
|
||||
@@ -57,7 +57,6 @@ export class RailsNewRunner {
|
||||
const baseCommand = 'rails';
|
||||
const baseArguments = ['new'];
|
||||
const commandExistsToRun = await commandExists(baseCommand);
|
||||
|
||||
if (commandExistsToRun) {
|
||||
const arrayExtraArguments = railsArgumentResolver(
|
||||
workspacePath,
|
||||
|
||||
@@ -14,8 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
const mockAccess = jest.fn();
|
||||
|
||||
import {
|
||||
DatabaseManager,
|
||||
getVoidLogger,
|
||||
@@ -43,7 +41,9 @@ import {
|
||||
import { createRouter, DatabaseTaskStore, TaskBroker } from '../index';
|
||||
import { StorageTaskBroker } from '../scaffolder/tasks/StorageTaskBroker';
|
||||
|
||||
jest.mock('fs-extra', () => ({
|
||||
const mockAccess = jest.fn();
|
||||
|
||||
jest.doMock('fs-extra', () => ({
|
||||
access: mockAccess,
|
||||
promises: {
|
||||
access: mockAccess,
|
||||
|
||||
Reference in New Issue
Block a user