code: def handle_test_results(test_results):
      expressions = test_results.split(" ")
  
      failed = 0
      success = 0
  
      # When the output is short enough, the output is surrounded by = signs: "== OUTPUT =="
      # When it is too long, those signs are not present.
      time_spent = (
          expressions[-2] if "=" in expressions[-1] else expressions[-1]
      )
  
      for i, expression in enumerate(expressions):
          if "failed" in expression:
              failed += int(expressions[i - 1])
          if "passed" in expression:
              success += int(expressions[i - 1])
  
      return failed, success, time_spent
  
imports: import ast
  import collections
  import functools
  import json
  import math
  import operator
  import os
  import re
  import sys
  import time
  from typing import Dict, List, Optional, Union
  import requests
  from slack_sdk import WebClient
label_desc: Use image node_id 1 for calling a global function with example usage: handle_test_results(test_results) and returns: failed,  success,  time_spent