parameters: (branch_name)
return_statement: return min(positions.keys(), key=positions.get)
docstring: >>> version_of_branch('tkt_white_this_is_not_a_ee_branch')
      'white'
docstring_summary: >>> version_of_branch('tkt_white_this_is_not_a_ee_branch')
      'white'
docstring_tokens: >>> version_of_branch ( tkt_white_this_is_not_a_ee_branch ) white
function: def version_of_branch(branch_name):
      """
      >>> version_of_branch('tkt_white_this_is_not_a_ee_branch')
      'white'
      """
      positions = {version: branch_name.find(version)
                   for version in VERSIONS}
      if all((pos < 0) for pos in positions.values()):
          # The branch name doesn't contain white, pink or black
          return
      positions = {version: pos
                   for (version, pos) in positions.items()
                   if pos >= 0}
      return min(positions.keys(), key=positions.get)
function_tokens: def version_of_branch ( branch_name ) : positions = { version : branch_name . find ( version ) for version in VERSIONS } if all ( ( pos < 0 ) for pos in positions . values ( ) ) : # The branch name doesn't contain white, pink or black return positions = { version : pos for ( version , pos ) in positions . items ( ) if pos >= 0 } return min ( positions . keys ( ) , key = positions . get )