Adding upstream version 5.3.0+dfsg.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
bc475d7d0d
commit
e1f69a237f
605 changed files with 15320 additions and 9495 deletions
14
scss/tests/sass-true/register.js
Normal file
14
scss/tests/sass-true/register.js
Normal file
|
@ -0,0 +1,14 @@
|
|||
'use strict'
|
||||
|
||||
const path = require('node:path')
|
||||
|
||||
const runnerPath = path.join(__dirname, 'runner').replace(/\\/g, '/')
|
||||
|
||||
require.extensions['.scss'] = (module, filename) => {
|
||||
const normalizedFilename = filename.replace(/\\/g, '/')
|
||||
|
||||
return module._compile(`
|
||||
const runner = require('${runnerPath}')
|
||||
runner('${normalizedFilename}', { describe, it })
|
||||
`, filename)
|
||||
}
|
17
scss/tests/sass-true/runner.js
Normal file
17
scss/tests/sass-true/runner.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
'use strict'
|
||||
|
||||
const fs = require('node:fs')
|
||||
const path = require('node:path')
|
||||
const { runSass } = require('sass-true')
|
||||
|
||||
module.exports = (filename, { describe, it }) => {
|
||||
const data = fs.readFileSync(filename, 'utf8')
|
||||
const TRUE_SETUP = '$true-terminal-output: false; @import "true";'
|
||||
const sassString = TRUE_SETUP + data
|
||||
|
||||
runSass(
|
||||
{ describe, it, sourceType: 'string' },
|
||||
sassString,
|
||||
{ loadPaths: [path.dirname(filename)] }
|
||||
)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue