Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use promisify util instead of manual method #639

Merged
merged 2 commits into from
Apr 10, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Breaking changes:
within that block inline.
(PR [#607](https://github.com/alphagov/govuk-frontend/pull/607))
- Prefix `$global-images` variable
(PR [#617](https://github.com/alphagov/govuk-frontend/pull/615))
(PR [#615](https://github.com/alphagov/govuk-frontend/pull/615))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌

- Simplified how we build stylesheets that target old versions of IE:
- Removed styles that target IE6 and IE7
- Replaced IE mixins with a simpler version for targeting IE8 specifically
Expand Down Expand Up @@ -76,9 +76,9 @@ Internal:

- Update project README with user research findings (PR [#617](https://github.com/alphagov/govuk-frontend/pull/615))

- Update component READMEs to use `import` statement (PR [#617](https://github.com/alphagov/govuk-frontend/pull/615))
- Update component READMEs to use `import` statement (PR [#615](https://github.com/alphagov/govuk-frontend/pull/615))

- Update component READMEs to use `import` statement (PR [#617](https://github.com/alphagov/govuk-frontend/pull/615))
- Use promisify util instead of manual method (PR [#639](https://github.com/alphagov/govuk-frontend/pull/639))

## 0.0.26-alpha (Breaking release)

Expand Down
13 changes: 2 additions & 11 deletions tasks/gulp/__tests__/check-individual-components-compile.test.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,14 @@
/* eslint-env jest */

const path = require('path')
const util = require('util')

const sass = require('node-sass')
const sassRender = util.promisify(sass.render)

const lib = require('../../../lib/file-helper')
const configPaths = require('../../../config/paths.json')

const sassRender = (options) => {
return new Promise((resolve, reject) => {
sass.render(options, (error, result) => {
if (error) {
return reject(error)
}
return resolve(result)
})
})
}

describe('Individual components', () => {
it('should compile individual scss files without throwing exceptions', done => {
const componentNames = lib.SrcFilteredComponentList.slice()
Expand Down