Skip to content

Commit e0c7652

Browse files
jamonholmgrenGantMan
authored andcommitted
⚒ Upgrades to the latest Gluegun beta (#177)
* ⚒ Upgrades to the latest Gluegun beta * Upgrades to Gluegun 2.0.0-beta.7
1 parent 63d996f commit e0c7652

File tree

18 files changed

+96
-58
lines changed

18 files changed

+96
-58
lines changed

__tests__/__mocks__/mockContext.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const realThing = require('gluegun')
1+
const realThing = require('gluegun/toolbox')
22
const realSolidarityContext = require('../../src/extensions/solidarity-extension')
33
realSolidarityContext(realThing)
44

@@ -51,7 +51,7 @@ const mockContext = {
5151
},
5252
prompt: {
5353
ask: jest.fn(({ name }) => Promise.resolve({ [name]: 'taco', createFile: true })),
54-
confirm: jest.fn(() => true)
54+
confirm: jest.fn(() => true),
5555
},
5656
solidarity: noConfigSolidarity,
5757
}

__tests__/command_helpers/binaryExists.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import binaryExists from '../../src/extensions/functions/binaryExists'
2-
import context from 'gluegun'
2+
import * as context from 'gluegun/toolbox'
33

44
const doesNotExistCLI = 'no_way_this_should_be_real'
55
const alwaysExistCLI = 'node'

__tests__/command_helpers/checkCLI.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const outOfDateCLI = {
1414
semver: '10.99',
1515
}
1616

17-
const context = require('gluegun')
17+
const context = require('gluegun/toolbox')
1818

1919
test('error on missing binary', async () => {
2020
expect(await checkCLI(doesNotExistCLI, context)).toBe(`Binary '${doesNotExistCLI.binary}' not found`)

__tests__/command_helpers/checkCLIForUpdates.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import checkCLIForUpdates from '../../src/extensions/functions/checkCLIForUpdates'
22

3-
import context from 'gluegun'
3+
import * as context from 'gluegun/toolbox'
44
const rule = {
55
rule: 'cli',
66
binary: 'bananas',

__tests__/command_helpers/checkDir.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import checkDir from '../../src/extensions/functions/checkDir'
2-
import context from 'gluegun'
2+
import * as context from 'gluegun/toolbox'
33

44
test('checkDir detects an existing dir', () => {
55
// Check for a known directory

__tests__/command_helpers/checkFile.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import checkFile from '../../src/extensions/functions/checkFile'
2-
import context from 'gluegun'
2+
import * as context from 'gluegun/toolbox'
33

44
test('checkFile detects an existing file', () => {
55
// known file

__tests__/command_helpers/checkRequirement.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { SolidarityRequirement } from '../../dist/types'
22
import { toPairs } from 'ramda'
3-
import { strings } from 'gluegun'
3+
import { strings } from 'gluegun/toolbox'
44

55
import checkRequirement from '../../src/extensions/functions/checkRequirement'
66
import solidarityExtension from '../../src/extensions/solidarity-extension'
@@ -21,7 +21,7 @@ const checkENV = require('../../src/extensions/functions/checkENV')
2121
jest.mock('../../src/extensions/functions/checkFile')
2222
const checkFile = require('../../src/extensions/functions/checkFile')
2323

24-
const context = require('gluegun')
24+
const context = require('gluegun/toolbox')
2525

2626
const badRule = toPairs({
2727
YARN: [{ rule: 'knope', binary: 'yarn' }],

__tests__/command_helpers/checkShell.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { ShellRule, SolidarityRunContext } from '../../src/types'
2-
import { strings } from 'gluegun'
2+
import { strings } from 'gluegun/toolbox'
33
const checkShell: any = require('../../src/extensions/functions/checkShell')
44

55
/**

__tests__/command_helpers/createPlugin.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ test('check result shape', () => {
66
})
77

88
test('investigate createPlugin', async () => {
9-
109
const result = await createPlugin(context)
1110
expect(result).toMatchSnapshot()
1211
expect(context.template.generate).toBeCalled()

__tests__/command_helpers/getSolidaritySettings.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { solidarity } from '../../src'
22
import getSolidaritySettings from '../../src/extensions/functions/getSolidaritySettings'
33

4-
const context = require('gluegun')
4+
const context = require('gluegun/toolbox')
55

66
describe('getSolidaritySettings', () => {
77
describe('w/ success', () => {

0 commit comments

Comments
 (0)