From 63d1715679fb714f4c8f5ae426106edf6988e7ab Mon Sep 17 00:00:00 2001 From: Nicola Soranzo Date: Tue, 15 Sep 2015 17:06:27 +0100 Subject: [PATCH] Fix API tests using collection_creates_pair tool. --- lib/galaxy/tools/__init__.py | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/lib/galaxy/tools/__init__.py b/lib/galaxy/tools/__init__.py index 263437fe72f..8c9ab61ffd5 100755 --- a/lib/galaxy/tools/__init__.py +++ b/lib/galaxy/tools/__init__.py @@ -295,15 +295,17 @@ class ToolOutput( ToolOutputBase ): class ToolOutputCollection( ToolOutputBase ): """ - Represents a HistoryDatasetCollectionAssociation of output datasets produced by a tool. + Represents a HistoryDatasetCollectionAssociation of output datasets produced + by a tool. + - + - - + + - + """ @@ -337,13 +339,10 @@ class ToolOutputCollection( ToolOutputBase ): if self.dynamic_structure: return [] - def to_part( ( element_identifier, output ) ): - return ToolOutputCollectionPart( self, element_identifier, output ) - # This line is probably not right - should verify structured_like # or have outputs and all outputs have name. if len( self.outputs ) > 1: - output_parts = map( to_part, self.outputs ) + output_parts = [ToolOutputCollectionPart(self, k, v) for k, v in self.outputs.iteritems()] else: # either must have specified structured_like or something worse if self.structure.structured_like: