summaryrefslogtreecommitdiff
path: root/src/engine/SCons/WarningsTests.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine/SCons/WarningsTests.py')
-rw-r--r--src/engine/SCons/WarningsTests.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/engine/SCons/WarningsTests.py b/src/engine/SCons/WarningsTests.py
index 2a6e0b0..39a1602 100644
--- a/src/engine/SCons/WarningsTests.py
+++ b/src/engine/SCons/WarningsTests.py
@@ -21,15 +21,15 @@
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/WarningsTests.py 4720 2010/03/24 03:14:11 jars"
+__revision__ = "src/engine/SCons/WarningsTests.py 5023 2010/06/14 22:05:46 scons"
import sys
import unittest
import SCons.Warnings
-class TestOutput:
+class TestOutput(object):
def __call__(self, x):
- args = x[0]
+ args = x.args[0]
if len(args) == 1:
args = args[0]
self.out = str(args)
@@ -94,10 +94,6 @@ class WarningsTestCase(unittest.TestCase):
"Foo")
assert to.out is None, to.out
- SCons.Warnings.warn(SCons.Warnings.MandatoryWarning,
- "Foo")
- assert to.out is None, to.out
-
SCons.Warnings.enableWarningClass(SCons.Warnings.Warning)
SCons.Warnings.warn(SCons.Warnings.DeprecatedWarning,
"Foo")
@@ -109,6 +105,10 @@ class WarningsTestCase(unittest.TestCase):
"Foo")
assert to.out is None, to.out
+ SCons.Warnings.warn(SCons.Warnings.MandatoryDeprecatedWarning,
+ "Foo")
+ assert to.out is None, to.out
+
# Dependency warnings should still be enabled though
SCons.Warnings.enableWarningClass(SCons.Warnings.Warning)
SCons.Warnings.warn(SCons.Warnings.DependencyWarning,