Skip to content

Commit

Permalink
chore(deps-dev): bump is-svg from 4.3.2 to 5.0.0 (#8959)
Browse files Browse the repository at this point in the history
* chore(deps-dev): bump is-svg from 4.3.2 to 5.0.0

Bumps [is-svg](https://github.com/sindresorhus/is-svg) from 4.3.2 to 5.0.0.
- [Release notes](https://github.com/sindresorhus/is-svg/releases)
- [Commits](sindresorhus/is-svg@v4.3.2...v5.0.0)

---
updated-dependencies:
- dependency-name: is-svg
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* import is-svg with async dynamic imports

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: chris48s <git@chris-shaw.dev>
Co-authored-by: chris48s <chris48s@users.noreply.github.com>
  • Loading branch information
3 people committed Apr 16, 2023
1 parent 1d69460 commit 6af9328
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 44 deletions.
4 changes: 3 additions & 1 deletion badge-maker/lib/badge-cli.spec.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict'

const path = require('path')
const isSvg = require('is-svg')
const { spawn } = require('child-process-promise')
const { expect, use } = require('chai')
use(require('chai-string'))
Expand All @@ -20,6 +19,7 @@ describe('The CLI', function () {
})

it('should produce default badges', async function () {
const { default: isSvg } = await import('is-svg')
const { stdout } = await runCli(['cactus', 'grown'])
expect(stdout)
.to.satisfy(isSvg)
Expand All @@ -28,11 +28,13 @@ describe('The CLI', function () {
})

it('should produce colorschemed badges', async function () {
const { default: isSvg } = await import('is-svg')
const { stdout } = await runCli(['cactus', 'grown', ':green'])
expect(stdout).to.satisfy(isSvg)
})

it('should produce right-color badges', async function () {
const { default: isSvg } = await import('is-svg')
const { stdout } = await runCli(['cactus', 'grown', '#abcdef'])
expect(stdout).to.satisfy(isSvg).and.to.include('#abcdef')
})
Expand Down
4 changes: 2 additions & 2 deletions badge-maker/lib/index.spec.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
'use strict'

const { expect } = require('chai')
const isSvg = require('is-svg')
const { makeBadge, ValidationError } = require('.')

describe('makeBadge function', function () {
it('should produce badge with valid input', function () {
it('should produce badge with valid input', async function () {
const { default: isSvg } = await import('is-svg')
expect(
makeBadge({
label: 'build',
Expand Down
7 changes: 4 additions & 3 deletions badge-maker/lib/make-badge.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
const { test, given, forCases } = require('sazerac')
const { expect } = require('chai')
const snapshot = require('snap-shot-it')
const isSvg = require('is-svg')
const prettier = require('prettier')
const makeBadge = require('./make-badge')

Expand Down Expand Up @@ -80,7 +79,8 @@ describe('The badge generator', function () {
})

describe('SVG', function () {
it('should produce SVG', function () {
it('should produce SVG', async function () {
const { default: isSvg } = await import('is-svg')
expect(makeBadge({ label: 'cactus', message: 'grown', format: 'svg' }))
.to.satisfy(isSvg)
.and.to.include('cactus')
Expand Down Expand Up @@ -113,7 +113,8 @@ describe('The badge generator', function () {
})
})

it('should replace undefined svg badge style with "flat"', function () {
it('should replace undefined svg badge style with "flat"', async function () {
const { default: isSvg } = await import('is-svg')
const jsonBadgeWithUnknownStyle = makeBadge({
label: 'name',
message: 'Bob',
Expand Down
47 changes: 10 additions & 37 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
"humanize-string": "^2.1.0",
"icedfrisby": "4.0.0",
"icedfrisby-nock": "^2.1.0",
"is-svg": "^4.3.2",
"is-svg": "^5.0.0",
"js-yaml-loader": "^1.2.2",
"jsdoc": "^4.0.2",
"lint-staged": "^13.2.1",
Expand Down

0 comments on commit 6af9328

Please sign in to comment.