code: def test_gp_params_setter():
      new_gp = gp.GP()
  
      try:
          new_gp.p_reproduction = "a"
      except:
          new_gp.p_reproduction = 0.75
  
      try:
          new_gp.p_reproduction = -1
      except:
          new_gp.p_reproduction = 0.75
  
      assert new_gp.p_reproduction == 0.75
  
      try:
          new_gp.p_mutation = "b"
      except:
          new_gp.p_mutation = 0.5
  
      try:
          new_gp.p_mutation = -1
      except:
          new_gp.p_mutation = 0.5
  
      assert new_gp.p_mutation == 0.5
  
      try:
          new_gp.p_crossover = "c"
      except:
          new_gp.p_crossover = 0.25
  
      try:
          new_gp.p_crossover = -1
      except:
          new_gp.p_crossover = 0.25
  
      assert new_gp.p_crossover == 0.25
  
      try:
          new_gp.prunning_ratio = "d"
      except:
          new_gp.prunning_ratio = 0.25
  
      try:
          new_gp.prunning_ratio = -1
      except:
          new_gp.prunning_ratio = 0.25
  
      assert new_gp.prunning_ratio == 0.25
  
file_path: opytimizer/tests/opytimizer/optimizers/evolutionary/test_gp.py
imports: import sys
  import numpy
  from opytimizer.core import function
  from opytimizer.optimizers.evolutionary import gp
  from opytimizer.spaces import tree
label_desc: Use image node_id 2 for calling a global function with example usage: test_gp_params_setter() without return types