Skip to content
This repository was archived by the owner on May 14, 2021. It is now read-only.

Commit e985c64

Browse files
committed
Added failing test for #55
1 parent 3c43e97 commit e985c64

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

test/fixtures/interpolations/valid.js

+12-1
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ const Box3 = styled(Box2)`
4242
`
4343

4444
// Multiline
45+
// prettier-ignore
4546
const Button4 = styled.button`
4647
display: block;
4748
${`
@@ -52,6 +53,7 @@ const Button4 = styled.button`
5253

5354
// Conditional
5455
const cond = true
56+
// prettier-ignore
5557
const Button5 = styled.button`
5658
display: block;
5759
${cond &&
@@ -63,11 +65,20 @@ const Button5 = styled.button`
6365

6466
// Conditional
6567
const cond2 = false
68+
// prettier-ignore
6669
const Button6 = styled.button`
6770
display: block;
6871
${cond2 &&
69-
`
72+
`
7073
color: ${cond2};
7174
`}
7275
background: blue;
7376
`
77+
78+
// Several interpolation strings
79+
// prettier-ignore
80+
const Button7 = styled.button`
81+
${`display: block;`}
82+
${`color: ${color};`}
83+
${`background: blue;`};
84+
`

test/interpolations.test.js

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ const path = require('path')
44
const processor = path.join(__dirname, '../src/index.js')
55
const rules = {
66
'block-no-empty': true,
7+
'declaration-block-no-duplicate-properties': true,
78
indentation: 2
89
}
910

0 commit comments

Comments
 (0)