This repository holds testing discussions and tests for the the Source Map debugging format. Specifically, we're looking to encourage discussion around:
- Manual and automated testing strategies for Source Maps
- Gathering a list of Soure Map generators and consumers
- General discussion around deviations between source maps
Open discussion happens in the GitHub issues.
Source Map spec:
- Repo: https://github.com/tc39/source-map
- Rendered spec: https://tc39.es/source-map/
This repo also contains cross-implementation test cases that can be run in test suites for source map implementations, including browser devtool and library test suites.
- The tests are included in the validator test suite here. You can run them with
npm test
.
The tests for Firefox are in the Mozilla source-map library:
- The upstream repo has a test file for running the spec tests from this repo. They can be run with
npm test
.
How to run in WebKit:
- Check out WebKit
cd
to the checked out WebKit directory.- Run
git am <this-repo>/webkit/0001-Add-harness-for-source-maps-spec-tests.patch
- Run
Tools/Scripts/build-webkit
(depending on the platform you may need to pass--gtk
or other flags) - Run
Tools/Scripts/run-webkit-tests LayoutTests/inspector/model/source-map-spec.html
(again, you may need--gtk
on Linux)
How to run in Chrome Devtools:
- Setup:
- Install depot_tools following this depot_tools guide
- Check out Chrome Devtools:
- Run
gclient config https://chromium.googlesource.com/devtools/devtools-frontend --unmanaged
- Run
cd devtools-frontend
- Run
gclient sync
- Run
gn gen out/Default
- Build:
- Run
autoninja -C out/Default
- Run
- Test:
- Run
npm run auto-unittest
- Run
- Apply patches from this repo:
- Run
git apply <path to .patch file>
indevtools-frontend
repo
- Run
More information about running Chrome Devtools without building Chromium can be found here