code: def test_majorize():
      """Test majorize function"""
      assert majorize(()) == []
      assert majorize((0,)) == []
      assert majorize((0, 1)) == []
      assert majorize((0, 1, 2)) == []
      assert majorize((-1, 0, 1, 2)) == [0]
      assert majorize(
          (0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1)
      ) == [0, 0.5, 1]
      assert majorize((0, 0.2, 0.4, 0.6, 0.8, 1)) == [0, 1]
      assert majorize((-0.4, -0.2, 0, 0.2, 0.4, 0.6, 0.8, 1)) == [0, 1]
      assert majorize(
          (-1, -0.8, -0.6, -0.4, -0.2, 0, 0.2, 0.4, 0.6, 0.8, 1)
      ) == [-1, 0, 1]
      assert majorize((0, 0.2, 0.4, 0.6, 0.8, 1, 1.2, 1.4, 1.6)) == [
          0,
          1,
      ]
      assert majorize(
          (0, 0.2, 0.4, 0.6, 0.8, 1, 1.2, 1.4, 1.6, 1.8, 2)
      ) == [0, 1, 2]
      assert majorize(
          (0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 110, 120)
      ) == [0, 50, 100]
      assert majorize(
          (
              0,
              2,
              4,
              6,
              8,
              10,
              12,
              14,
              16,
              18,
              20,
              22,
              24,
              26,
              28,
              30,
              32,
              34,
              36,
          )
      ) == [0, 10, 20, 30]
      assert majorize((0, 1, 2, 3, 4, 5)) == [0, 5]
      assert majorize((-5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5)) == [
          -5,
          0,
          5,
      ]
      assert majorize((-5, 5, -4, 4, 0, 1, -1, 3, -2, 2, -3)) == [
          -5,
          0,
          5,
      ]
      assert majorize((0, 1, 2, 3, 4)) == [0]
      assert majorize((3, 4, 5, 6)) == [5]
      assert majorize((0, 1, 2, 3, 4, 5, 6, 7, 8)) == [0, 5]
      assert majorize((-5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5)) == [
          -5,
          0,
          5,
      ]
      assert majorize((-6, -5, -4, -3, -2, -1, 0, 1, 2, 3)) == [-5, 0]
      assert majorize((-6, -5, -4, -3)) == [-5]
      assert majorize((1, 10, 100, 1000, 10000, 100000)) == []
      assert majorize(range(30, 70, 5)) == [30, 40, 50, 60]
      assert majorize(range(20, 55, 2)) == [20, 30, 40, 50]
      assert majorize(range(21, 83, 3)) == [30, 45, 60, 75]
  
file_path: pygal/pygal/test/test_util.py
imports: from pytest import raises
  from pygal.util import _swap_curly, majorize, mergextend, minify_css, round_to_float, round_to_int, template, truncate
label_desc: Use image node_id 7 for calling a global function with example usage: test_majorize() without return types