-
Notifications
You must be signed in to change notification settings - Fork 157
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow sbt-scoverage to work on Windows
The -Xplugin option expects a classpath string with multiple paths separated by a semicolon or colon depending on the operating system. However, this currently always uses a colon, which doesn't work on Windows. This means scalac cannot find the scoverage plugin jars and leads to errors about "bad options". This modifies the -Xplugin logic to use File.pathSeparator when building the Xplugin classpath, allowing it to work regardless of operating system. Also modifies excludedPackages when on Windows to replace Unix path separators with Windows path separators (which are escaped because it is treated as a regular expression). Modifies tests to remove unnecessary escaping of Unix separators that results in an invalid regex due to this replacement on Windows. Note that two tests currently prevent CI from working on Windows: coverage-off and preserve-set. The reason for these failures on Windows is not clear, but these changes at least allow the common uses to work on Windows.
- Loading branch information
1 parent
98c69fb
commit 8ba258c
Showing
4 changed files
with
13 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters