Skip to content
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
18 changes: 11 additions & 7 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
node-version: [lts/*]
node-version: ["lts/*"]

runs-on: ${{ matrix.os }}

Expand All @@ -32,15 +32,17 @@ jobs:
cancel-in-progress: true

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
architecture: "x64"
cache: "yarn"
cache-dependency-path: "yarn.lock"

- name: Install dependencies
run: yarn --frozen-lockfile
Expand All @@ -54,7 +56,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
node-version: [10.x, 12.x, 14.x, 16.x, 18.x, 20.x]
node-version: ["10", "12", "14", "16", "18", "20"]
webpack-version: [latest]

runs-on: ${{ matrix.os }}
Expand All @@ -68,13 +70,15 @@ jobs:
if: matrix.os == 'windows-latest'
run: git config --global core.autocrlf input

- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
node-version: "${{ matrix.node-version }}"
architecture: "x64"
cache: "yarn"
cache-dependency-path: "yarn.lock"

- name: Install dependencies
run: yarn --frozen-lockfile
Expand Down
6 changes: 6 additions & 0 deletions test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -850,6 +850,12 @@ const tests = [
options: { mode: "pure" },
expected: ":local(.foo) { &:hover { a_value: some-value; } }",
},
{
name: "consider global inside local as pure",
input: ".foo button { a_value: some-value; }",
options: { mode: "pure" },
expected: ":local(.foo) button { a_value: some-value; }",
},
{
name: "consider selector & statements as pure",
input: ".foo { html &:hover { a_value: some-value; } }",
Expand Down