Don't turn on global warnings via shebang parsing in tests #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A tests in t/06-compiler.t was broken because it relied on $^W being
true via the shebang being parsed. Mason actually doesn't turn on
warnings for you by default, and these tests were just implicitly
relying on perl setting $^W because it would parse the shebang of this
file.
Do a "use warnings" in t/06-compiler.t and other tests instead of
turning $^W on implicitly via the shebang.
fix tests that were relying on global warnings not to not do
so (Mason won't warn about runtime warnings like "$x + undef" by
default), and add new tests to show that the previous behavior only
kicks in if you add an explicit "use warnings".
Remove the shebangs for all tests except t/12-taint.t, where it's
actually used to enable taint support.
This is needed because I was going to add a use_warnings option similar
to use_strict, but couldn't actually test for it because it didn't do
anything, because warnings were globally enabled!