mirror of
https://github.com/idanoo/GoScrobble
synced 2025-07-01 13:42:20 +00:00
0.2.0 - Mid migration
This commit is contained in:
parent
139e6a915e
commit
7e38fdbd7d
42393 changed files with 5358157 additions and 62 deletions
56
web/node_modules/postcss-attribute-case-insensitive/test/test.js
generated
vendored
Executable file
56
web/node_modules/postcss-attribute-case-insensitive/test/test.js
generated
vendored
Executable file
|
@ -0,0 +1,56 @@
|
|||
import postcss from 'postcss';
|
||||
import { expect } from 'chai';
|
||||
|
||||
import plugin from '..';
|
||||
|
||||
const test = (input, output, opts, done) => {
|
||||
postcss([
|
||||
plugin(opts)
|
||||
])
|
||||
.process(input, { from: '<inline>' })
|
||||
.then(result => {
|
||||
expect(result.css).to.eql(output);
|
||||
expect(result.warnings()).to.be.empty; // eslint-disable-line no-unused-expressions
|
||||
|
||||
done();
|
||||
})
|
||||
.catch(done);
|
||||
};
|
||||
|
||||
describe('postcss-attribute-case-insensitive', () => {
|
||||
it('simple', done => {
|
||||
test(
|
||||
'[data-foo=test i] { display: block; }',
|
||||
'[data-foo=test],[data-foo=Test],[data-foo=tEst],[data-foo=TEst],[data-foo=teSt],[data-foo=TeSt],[data-foo=tESt],[data-foo=TESt],[data-foo=tesT],[data-foo=TesT],[data-foo=tEsT],[data-foo=TEsT],[data-foo=teST],[data-foo=TeST],[data-foo=tEST],[data-foo=TEST] { display: block; }',
|
||||
{},
|
||||
done
|
||||
);
|
||||
});
|
||||
|
||||
it('with spaces', done => {
|
||||
test(
|
||||
'[foo="a b" i]{}',
|
||||
'[foo="a b"],[foo="A b"],[foo="a B"],[foo="A B"]{}',
|
||||
{},
|
||||
done
|
||||
);
|
||||
});
|
||||
|
||||
it('not insensitive', done => {
|
||||
test(
|
||||
'[foo=a]{}',
|
||||
'[foo=a]{}',
|
||||
{},
|
||||
done
|
||||
);
|
||||
});
|
||||
|
||||
it('several attributes', done => {
|
||||
test(
|
||||
'[foo=a i],[foobar=b],[bar=c i]{}',
|
||||
'[foobar=b],[foo=a],[foo=A],[bar=c],[bar=C]{}',
|
||||
{},
|
||||
done
|
||||
);
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue