Skip to content

Commit

Permalink
Fix bug in IAlgorithm::categories export. Refs #6677
Browse files Browse the repository at this point in the history
  • Loading branch information
martyngigg committed Mar 14, 2013
1 parent a55922e commit 744536b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ void export_ialgorithm()
.def("alias", &IAlgorithm::alias, "Return the aliases for the algorithm")
.def("version", &IAlgorithm::version, "Returns the version number of the algorithm")
.def("category", &IAlgorithm::category, "Returns the category containing the algorithm")
.def("categories", &IAlgorithm::category, "Returns the list of categories this algorithm belongs to")
.def("categories", &IAlgorithm::categories, "Returns the list of categories this algorithm belongs to")
.def("getOptionalMessage", &IAlgorithm::getOptionalMessage, "Returns the optional user message attached to the algorithm")
.def("getWikiSummary", &IAlgorithm::getWikiSummary, "Returns the summary found on the wiki page")
.def("getWikiDescription", &IAlgorithm::getWikiDescription, "Returns the description found on the wiki page using wiki markup")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@ def setUp(self):
self._load.initialize()

def test_alg_attrs_are_correct(self):
self.assertTrue(self._load.name(), 'Load')
self.assertTrue(self._load.version(), 1)
self.assertTrue(self._load.category(), 'DataHandling')
self.assertEquals('Load', self._load.name())
self.assertEquals(1, self._load.version())
self.assertEquals('DataHandling', self._load.category())
self.assertEquals(1, len(self._load.categories()))
self.assertEquals('DataHandling', self._load.categories()[0])

def test_get_unknown_property_raises_error(self):
self.assertRaises(RuntimeError, self._load.getProperty, "NotAProperty")
Expand Down

0 comments on commit 744536b

Please sign in to comment.