Go Test Fader

Go Test Fader visually de-emphasizes Go test filenames so production files are
easier to scan in VS Code. By default, every file matching **/*_test.go gets a
semi-transparent foreground color in the Explorer and Open Editors views.
Features
- Fades Go test filenames without changing their contents.
- Supports customizable include and exclude globs.
- Updates immediately when extension settings change.
- Activates immediately in Go workspaces without requiring a window reload.
- Allows any VS Code theme-color token to be used.
- Supports a small optional badge and hover tooltip.
- Includes commands to toggle or refresh the decorations.
Settings
{
"goTestFader.enabled": true,
"goTestFader.include": ["**/*_test.go"],
"goTestFader.exclude": ["**/vendor/**"],
"goTestFader.matchCase": true,
"goTestFader.foreground": "goTestFader.testFileForeground",
"goTestFader.badge": "",
"goTestFader.showTooltip": true
}
To choose the exact fade color and opacity, customize the contributed color in
your user or workspace settings.json:
{
"workbench.colorCustomizations": {
"goTestFader.testFileForeground": "#80808066"
}
}
The final two hexadecimal digits are the alpha value: lower values make the
filename more transparent. You can instead set goTestFader.foreground to any
existing VS Code theme-color ID, such as descriptionForeground.
Example that also fades Go fixtures and shows a badge:
{
"goTestFader.include": [
"**/*_test.go",
"**/testdata/**/*.go"
],
"goTestFader.exclude": [
"**/vendor/**",
"**/generated/**"
],
"goTestFader.badge": "T"
}
Commands
Go Test Fader: Toggle
Go Test Fader: Refresh Decorations
Run locally
npm install
code .
Press F5 in VS Code to launch an Extension Development Host. To build an
installable package:
npm run package
code --install-extension go-test-fader-0.1.2.vsix
Once the Marketplace release is available, you can also install it from VS Code
by searching for Go Test Fader, or from the command line:
code --install-extension kiarashAlizadeh.go-test-fader
VS Code limitation
The supported file-decoration API applies to resource views such as Explorer
and Open Editors. VS Code currently does not expose a supported extension API
for independently changing editor-tab filename colors, so this extension does
not recolor tabs.
Development
Run the syntax checks and unit tests with:
npm run check
Contributing
Bug reports and pull requests are welcome. Please run npm run check before
opening a pull request.
License
MIT © 2026 Kiarash Alizadeh