private Object[] computeFrameLocals() {
    return computeFrameLocals(argsSize, locals, newLocals, variableMapper);
  }
@Test
  public void testComplexSparkContextInit() {
    Object[] expected = {
      "org/apache/spark/SparkContext",
      "org/apache/spark/SparkConf",
      "java/util/concurrent/ConcurrentMap",
      "scala/Option",
      "java/lang/String",
      0,
      0,
      1,
      "scala/Option",
      "scala/Tuple2",
      "org/apache/spark/scheduler/SchedulerBackend",
      "org/apache/spark/scheduler/TaskScheduler",
      "scala/Tuple2",
      "scala/Tuple2",
      "org/apache/spark/scheduler/SchedulerBackend",
      "org/apache/spark/scheduler/TaskScheduler",
      "scala/Option",
      0,
      1,
      "org/apache/spark/scheduler/SchedulerBackend",
      "scala/Option"
    };
    VariableMapper mapper =
        new VariableMapper(
            2,
            21,
            new int[] {
              0,
              0,
              -2147483628,
              -2147483636,
              -2147483646,
              -2147483645,
              -2147483644,
              -2147483643,
              -2147483642,
              -2147483641,
              -2147483640,
              -2147483635,
              -2147483639,
              -2147483638,
              -2147483637,
              -2147483634,
              -2147483633,
              -2147483632,
              -2147483631,
              -2147483630,
              -2147483629,
              0,
              0,
              0,
              0,
              0,
              0,
              0,
              0,
              0,
              0,
              0
            });

    Object[] fromFrame = {
      "org/apache/spark/SparkContext",
      "org/apache/spark/SparkConf",
      0,
      0,
      "scala/Option",
      "scala/Tuple2",
      "java/util/concurrent/ConcurrentMap",
      "scala/Option",
      "java/lang/String",
      0,
      0,
      1,
      "scala/Option",
      "scala/Tuple2",
      "scala/Tuple2",
      "org/apache/spark/scheduler/SchedulerBackend",
      "org/apache/spark/scheduler/TaskScheduler",
      "org/apache/spark/scheduler/SchedulerBackend",
      "org/apache/spark/scheduler/TaskScheduler",
      "scala/Option",
      0,
      1,
      "org/apache/spark/scheduler/SchedulerBackend"
    };
    Object[] locals =
        InstrumentingMethodVisitor.computeFrameLocals(2, Arrays.asList(fromFrame), null, mapper);
    assertArrayEquals(expected, locals);
  }