Augie Fackler avatar Augie Fackler committed 46f6b87

tests: Fix some missing suite definitions so that running the full testsuite
does not require installing nose.

Comments (0)

Files changed (3)

 
 sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
+import test_diff
 import test_fetch_branches
 import test_fetch_command
 import test_fetch_command_regexes
 import test_push_dirs
 import test_push_eol
 import test_tags
+import test_utility_commands
 
 def suite():
-    return unittest.TestSuite([test_fetch_branches.suite(),
+    return unittest.TestSuite([test_diff.suite(),
+                               test_fetch_branches.suite(),
                                test_fetch_command.suite(),
                                test_fetch_command_regexes.suite(),
                                test_fetch_exec.suite(),
                                test_push_dirs.suite(),
                                test_push_eol.suite(),
                                test_tags.suite(),
+                               test_utility_commands.suite(),
                               ])
 
 if __name__ == '__main__':

tests/test_diff.py

+import unittest
+
 from mercurial import ui
 
 import diff_cmd
         u = ui.ui()
         diff_cmd.diff_command(u, self.repo, self.wc_path)
         self.assertEqual(u.stream.getvalue(), expected_diff_output)
+
+
+def suite():
+    all = [unittest.TestLoader().loadTestsFromTestCase(DiffTests),
+          ]
+    return unittest.TestSuite(all)

tests/test_utility_commands.py

 import os
+import unittest
 import urllib # for url quoting
 
 from mercurial import ui
         utility_commands.print_wc_url(u, self.repo, self.wc_path)
         expected = 'file://%s\n' % urllib.quote(self.repo_path)
         self.assertEqual(u.stream.getvalue(), expected)
+
+
+def suite():
+    all = [unittest.TestLoader().loadTestsFromTestCase(UtilityTests),
+          ]
+    return unittest.TestSuite(all)
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.