#2503 make singletons compared with "is" not == or !=
Thanks to Wummel for the patch
diff --git a/Lib/test/test_ast.py b/Lib/test/test_ast.py
index 03dd5b5..e4f87f2 100644
--- a/Lib/test/test_ast.py
+++ b/Lib/test/test_ast.py
@@ -130,7 +130,7 @@
 
 def test_order(ast_node, parent_pos):
 
-    if not isinstance(ast_node, _ast.AST) or ast_node._fields == None:
+    if not isinstance(ast_node, _ast.AST) or ast_node._fields is None:
         return
     if isinstance(ast_node, (_ast.expr, _ast.stmt, _ast.excepthandler)):
         node_pos = (ast_node.lineno, ast_node.col_offset)
@@ -141,7 +141,7 @@
         if isinstance(value, list):
             for child in value:
                 test_order(child, parent_pos)
-        elif value != None:
+        elif value is not None:
             test_order(value, parent_pos)
 
 def run_tests():
diff --git a/Lib/test/test_mailbox.py b/Lib/test/test_mailbox.py
index 83802c1..7a12258 100644
--- a/Lib/test/test_mailbox.py
+++ b/Lib/test/test_mailbox.py
@@ -630,9 +630,9 @@
                                                                 "tmp")),
                              "File in wrong location: '%s'" % head)
             match = pattern.match(tail)
-            self.assert_(match != None, "Invalid file name: '%s'" % tail)
+            self.assert_(match is not None, "Invalid file name: '%s'" % tail)
             groups = match.groups()
-            if previous_groups != None:
+            if previous_groups is not None:
                 self.assert_(int(groups[0] >= previous_groups[0]),
                              "Non-monotonic seconds: '%s' before '%s'" %
                              (previous_groups[0], groups[0]))
diff --git a/Lib/test/test_pyclbr.py b/Lib/test/test_pyclbr.py
index d1291a0..d747f2f 100644
--- a/Lib/test/test_pyclbr.py
+++ b/Lib/test/test_pyclbr.py
@@ -57,7 +57,7 @@
             ignore are ignored.   If no module is provided, the appropriate
             module is loaded with __import__.'''
 
-        if module == None:
+        if module is None:
             # Import it.
             # ('<silly>' is to work around an API silliness in __import__)
             module = __import__(moduleName, globals(), {}, ['<silly>'])
diff --git a/Lib/test/test_ssl.py b/Lib/test/test_ssl.py
index f5ae026..856434f 100644
--- a/Lib/test/test_ssl.py
+++ b/Lib/test/test_ssl.py
@@ -546,7 +546,7 @@
                           expectedToWork,
                           certsreqs=None):
 
-        if certsreqs == None:
+        if certsreqs is None:
             certsreqs = ssl.CERT_NONE
 
         if certsreqs == ssl.CERT_NONE: