Skip to content

Commit fae8ed0

Browse files
test: devtool
1 parent 884cbfe commit fae8ed0

File tree

11 files changed

+70
-3
lines changed

11 files changed

+70
-3
lines changed

.github/workflows/nodejs.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ jobs:
4343
- name: Lint
4444
run: npm run lint
4545

46-
# - name: Security audit
47-
# run: npm run security
46+
- name: Security audit
47+
run: npm run security
4848

4949
- name: Check commit message
5050
uses: wagoid/commitlint-github-action@v1
@@ -55,7 +55,6 @@ jobs:
5555
strategy:
5656
matrix:
5757
os: [ubuntu-latest, windows-latest, macos-latest]
58-
# css-loader doesn't support node@6
5958
node-version: [10.x, 12.x, 14.x]
6059
webpack-version: [latest, next]
6160

test/cases/devtool-source-map-no-source-maps-from-css-loader/expected/main.css

+6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/cases/devtool-source-map-no-source-maps-from-css-loader/expected/main.css.map

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
import './style.css';
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
body {
2+
background: red;
3+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import Self from '../../../src';
2+
3+
module.exports = {
4+
entry: './index.js',
5+
devtool: 'source-map',
6+
module: {
7+
rules: [
8+
{
9+
test: /\.css$/,
10+
use: [
11+
Self.loader,
12+
{
13+
loader: 'css-loader',
14+
options: {
15+
sourceMap: false,
16+
},
17+
},
18+
],
19+
},
20+
],
21+
},
22+
plugins: [
23+
new Self({
24+
filename: '[name].css',
25+
}),
26+
],
27+
};

test/cases/devtool-source-map/expected/main.css

+6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/cases/devtool-source-map/expected/main.css.map

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
import './style.css';
+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
body {
2+
background: red;
3+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import Self from '../../../src';
2+
3+
module.exports = {
4+
entry: './index.js',
5+
devtool: 'source-map',
6+
module: {
7+
rules: [
8+
{
9+
test: /\.css$/,
10+
use: [Self.loader, 'css-loader'],
11+
},
12+
],
13+
},
14+
plugins: [
15+
new Self({
16+
filename: '[name].css',
17+
}),
18+
],
19+
};

0 commit comments

Comments
 (0)