code: def test_issue_6360():
      a, b = symbols("a b")
      apb = a + b
      eq = apb + apb**2 * (-2 * a - 2 * b)
      assert factor_terms(sub_pre(eq)) == a + b - 2 * (a + b) ** 3
  
imports: from sympy.concrete.summations import Sum
  from sympy.core.add import Add
  from sympy.core.basic import Basic
  from sympy.core.containers import Dict, Tuple
  from sympy.core.function import Function
  from sympy.core.mul import Mul
  from sympy.core.numbers import I, Rational, oo
  from sympy.core.singleton import S
  from sympy.core.symbol import Dummy, Symbol, symbols
  from sympy.functions.elementary.exponential import exp, log
  from sympy.functions.elementary.miscellaneous import root, sqrt
  from sympy.functions.elementary.trigonometric import cos, sin
  from sympy.integrals.integrals import Integral
  from sympy.series.order import O
  from sympy.sets.sets import Interval
  from sympy.simplify.radsimp import collect
  from sympy.simplify.simplify import simplify
  from sympy.core.exprtools import decompose_power, Factors, Term, _gcd_terms, gcd_terms, factor_terms, factor_nc, _mask_nc, _monotonic_sign
  from sympy.core.mul import _keep_coeff
  from sympy.simplify.cse_opts import sub_pre
  from sympy.testing.pytest import raises
  from sympy.abc import a, b, t, x, y, z
label_desc: Use image node_id 8 for calling a global function with example usage: test_issue_6360() without return types