Code review comment: @warunalakshitha @MaryamZi Ack.. I'll modify the debugger side to preprocess the type string before sending it to the frontend.

Code under review:
public void variableReferenceEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, NIL_VAR, "()", "nil");
        
        debugTestRunner.assertExpression(context, BOOLEAN_VAR, "true", "boolean");
        
        debugTestRunner.assertExpression(context, INT_VAR, "20", "int");
        
        debugTestRunner.assertExpression(context, FLOAT_VAR, "-10.0", "float");
        
        debugTestRunner.assertExpression(context, DECIMAL_VAR, "3.5", "decimal");
        
        debugTestRunner.assertExpression(context, STRING_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, XML_VAR, "<person " +
                "gender=\"male\"><firstname>Praveen</firstname><lastname>Nada</lastname></person>", "xml");
        
        debugTestRunner.assertExpression(context, ARRAY_VAR, "any[4]", "array");
        
        debugTestRunner.assertExpression(context, TUPLE_VAR, "tuple[int,string]", "tuple");
        
        debugTestRunner.assertExpression(context, MAP_VAR, "map", "map");
        
        debugTestRunner.assertExpression(context, RECORD_VAR, " /:@[`{~π_123_ƮέŞŢ_Student", "record");
        
        debugTestRunner.assertExpression(context, ANON_RECORD_VAR, "record {| string city; string country; |}",
                "record");
        
        debugTestRunner.assertExpression(context, ERROR_VAR, "SimpleErrorType", "error");
        
        debugTestRunner.assertExpression(context, ANON_FUNCTION_VAR, "function isolated function (string,string) " +
                                                 "returns (string)",
                "function");
        
        debugTestRunner.assertExpression(context, FUTURE_VAR, "future", "future");
        
        debugTestRunner.assertExpression(context, OBJECT_VAR, "Person_\\ /<>:@[`{~π_ƮέŞŢ", "object");
        
        debugTestRunner.assertExpression(context, TYPEDESC_VAR, "int", "typedesc");
        
        debugTestRunner.assertExpression(context, UNION_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, OPTIONAL_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, ANY_VAR, "15.0", "float");
        
        debugTestRunner.assertExpression(context, ANYDATA_VAR, "619", "int");
        
        debugTestRunner.assertExpression(context, BYTE_VAR, "128", "int");
        
        debugTestRunner.assertExpression(context, TABLE_VAR, "table<Employee>[3]", "table");
        
        debugTestRunner.assertExpression(context, STREAM_VAR, "stream<int>", "stream");
        
        debugTestRunner.assertExpression(context, NEVER_VAR, "", "xml");
        
        debugTestRunner.assertExpression(context, JSON_VAR, "map<json>", "json");
        
        debugTestRunner.assertExpression(context, ANON_OBJECT_VAR, "Person_\\ /<>:@[`{~π_ƮέŞŢ", "object");

        
        
        
        debugTestRunner.assertExpression(context, GLOBAL_VAR_03, "map", "map");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_04, "()", "nil");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_05, "()", "nil");
        
        debugTestRunner.assertExpression(context, GLOBAL_VAR_06, "Ballerina", "string");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_07, "100.0", "decimal");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_08, "2", "int");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_09, "2.0", "float");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_10, "map<json>", "json");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_11, "IL with global var", "string");

        
    }

    @Override
    @Test
    public void fieldAccessEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, OBJECT_VAR + ".address", "No 20, Palm grove", "string");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + ".'Ȧɢέ_\\ \\/\\:\\@\\[\\`\\{\\~π", "20", "int");
        
        debugTestRunner.assertExpression(context, JSON_VAR + ".name", "John", "string");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + ".grades.maths", "80", "int");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + "?.undefined", "()", "nil");
    }

    @Override
    @Test
    public void xmlAttributeAccessEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void annotationAccessEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void memberAccessEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, STRING_VAR + "[0]", "f", "string");
        
        debugTestRunner.assertExpression(context, ARRAY_VAR + "[0]", "1", "int");
        
        
        
        
        
        
        
        
    }

    @Override
    @Test
    public void functionCallEvaluationTest() throws BallerinaTestException {

        

        
        
        debugTestRunner.assertExpression(context, " calculate ( 5 , 6 , 7 ) ;", "38", "int");

        
        
        debugTestRunner.assertExpression(context, "calculate ( 5 , c  =  7 , b  =  6 );", "38", "int");

        

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500)", "[2500, 20, 0.02]", "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, annualIncrement = 100)",
                "[2500, 100, 0.02]", "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, 100);", "[2500, 100, 0.02]", "string");

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, bonusRate = 0.1);", "[2500, 20, 0.1]",
                "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, 20, 0.1);", "[2500, 20, 0.1]", "string");

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, annualIncrement = 100, bonusRate = 0.1);",
                "[2500, 100, 0.1]", "string");

        
        
        
        debugTestRunner.assertExpression(context,
                "printSalaryDetails(annualIncrement = 100, baseSalary = 2500, bonusRate = 0.1);",
                "[2500, 100, 0.1]", "string");

        
        

        
        

        
        
        

        
        
        
        

        
        
        
        

        
        
        
        
    }

    @Override
    @Test
    public void methodCallEvaluationTest() throws BallerinaTestException {

        
        debugTestRunner.assertExpression(context, OBJECT_VAR + ".getSum(34,56)", "90", "int");

        

        
        debugTestRunner.assertExpression(context, ARRAY_VAR + ".length()", "4", "int");
        debugTestRunner.assertExpression(context, ARRAY_VAR + ".slice(1,3)", "any[2]", "array");

        
        
        debugTestRunner.assertExpression(context, DECIMAL_VAR + ".round()", "4", "decimal");
        debugTestRunner.assertExpression(context, DECIMAL_VAR + ".abs()", "3.5", "decimal");
        
        debugTestRunner.assertExpression(context, ERROR_VAR + ".message()", "SimpleErrorType", "string");
        
        debugTestRunner.assertExpression(context, FLOAT_VAR + ".sin()", "0.5440211108893698", "float");
        debugTestRunner.assertExpression(context, FLOAT_VAR + ".pow(3.0)", "-1000.0", "float");
        
        debugTestRunner.assertExpression(context, FUTURE_VAR + ".cancel()", "()", "nil");
        
        debugTestRunner.assertExpression(context, INT_VAR + ".abs()", "20", "int");
        
        debugTestRunner.assertExpression(context, MAP_VAR + ".get(\"country\")", "Sri Lanka", "string");
        
        
        
        
        debugTestRunner.assertExpression(context, STRING_VAR + ".getCodePoint(1)", "111", "int");
        debugTestRunner.assertExpression(context, STRING_VAR + ".substring(1,3)", "oo", "string");
        
        

        
        debugTestRunner.assertExpression(context, TYPEDESC_VAR + ".toBalString()", "typedesc int", "string");

        
        debugTestRunner.assertExpression(context, XML_VAR + ".getName()", "person", "string");
        debugTestRunner.assertExpression(context, XML_VAR + ".children()",
                "<firstname>Praveen</firstname><lastname>Nada</lastname>", "xml");
    }

    @Override
    @Test
    public void errorConstructorEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void anonymousFunctionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void letExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void typeCastEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("<float>%s", ANYDATA_VAR), "619.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("<float|boolean>%s", ANYDATA_VAR), "619.0", "float");
    }

    @Override
    @Test
    public void typeOfExpressionEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("typeof %s", BOOLEAN_VAR), "boolean", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s", INT_VAR), "int", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s", FLOAT_VAR), "float", "typedesc");
        
        debugTestRunner.assertExpression(context, String.format("typeof %s", JSON_VAR), "map<json>", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s[0]", STRING_VAR), "string", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof typeof %s", BOOLEAN_VAR), "typedesc",
                "typedesc");
    }

    @Override
    @Test
    public void unaryExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("+%s", INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("+%s", FLOAT_VAR), "-10.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("+%s", DECIMAL_VAR), "3.5", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("-%s", INT_VAR), "-20", "int");
        
        debugTestRunner.assertExpression(context, String.format("-%s", FLOAT_VAR), "10.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("-%s", DECIMAL_VAR), "-3.5", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("~%s", INT_VAR), "-21", "int");

        
        
        debugTestRunner.assertExpression(context, String.format("!%s", BOOLEAN_VAR), "false", "boolean");
    }

    @Override
    @Test
    public void multiplicativeExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", INT_VAR, INT_VAR), "400", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", FLOAT_VAR, FLOAT_VAR), "100.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", DECIMAL_VAR, DECIMAL_VAR), "12.25",
                "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", INT_VAR, INT_VAR), "1", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", FLOAT_VAR, FLOAT_VAR), "1.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", DECIMAL_VAR, DECIMAL_VAR), "1", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", INT_VAR, INT_VAR), "0", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", FLOAT_VAR, FLOAT_VAR), "-0.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", DECIMAL_VAR, DECIMAL_VAR), "0",
                "decimal");
    }

    @Override
    @Test
    public void additiveExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", INT_VAR, INT_VAR), "40", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", FLOAT_VAR, FLOAT_VAR), "-20.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", DECIMAL_VAR, DECIMAL_VAR), "7.0", "decimal");

        
        debugTestRunner.assertExpression(context, String.format("%s + %s", STRING_VAR, STRING_VAR), "foofoo", "string");
        
        debugTestRunner.assertExpression(context, "\" one \" + \" two \" + \" three \"", " one  two  three ", "string");
        
        String bStringTemplateExpr = String.format("string `name: ${%s}, age: ${%s}`", STRING_VAR, INT_VAR);
        debugTestRunner.assertExpression(context, String.format("%s + %s + %s", bStringTemplateExpr,
                bStringTemplateExpr, bStringTemplateExpr), "name: foo, age: 20name: foo, age: 20name: foo, age: 20",
                "string");

        
        debugTestRunner.assertExpression(context, String.format("%s + %s", XML_VAR, XML_VAR),
                "<person gender=\"male\">" +
                        "<firstname>Praveen</firstname><lastname>Nada</lastname></person><person gender=\"male\">" +
                        "<firstname>Praveen</firstname><lastname>Nada</lastname></person>", "xml");

        
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", INT_VAR, INT_VAR), "0", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", FLOAT_VAR, FLOAT_VAR), "0.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", DECIMAL_VAR, DECIMAL_VAR), "0", "decimal");
    }

    @Override
    @Test
    public void shiftExpressionEvaluationTest() throws BallerinaTestException {
        debugTestRunner.assertExpression(context, String.format("%s << %s", INT_VAR, INT_VAR), "20971520", "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR), "-2000",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "2000", "int");

        debugTestRunner.assertExpression(context, String.format("%s >> %s", INT_VAR, INT_VAR), "0", "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "-1",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR), "-500",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR), "500",
                "int");

        debugTestRunner.assertExpression(context, String.format("%s >>> %s", INT_VAR, INT_VAR), "0", "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "1",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "9223372036854775308",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "500", "int");
    }

    @Override
    @Test
    public void rangeExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void comparisonEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", NIL_VAR, NIL_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", BOOLEAN_VAR, BOOLEAN_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", INT_VAR, INT_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", FLOAT_VAR, FLOAT_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", DECIMAL_VAR, DECIMAL_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", STRING_VAR, STRING_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "booleanArrayVar", "booleanArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "intArrayVar", "intArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "floatArrayVar", "floatArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "decimalArrayVar", "decimalArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "stringArrayVar", "stringArrayVar"),
                "false", "boolean");

        
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", NIL_VAR, NIL_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", BOOLEAN_VAR, BOOLEAN_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", INT_VAR, INT_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", FLOAT_VAR, FLOAT_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", DECIMAL_VAR, DECIMAL_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", STRING_VAR, STRING_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "booleanArrayVar", "booleanArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "intArrayVar", "intArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "floatArrayVar", "floatArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "decimalArrayVar", "decimalArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "stringArrayVar", "stringArrayVar"),
                "true", "boolean");

        
        
        
        
        debugTestRunner.assertExpression(context, String.format("%s > %s", INT_VAR, INT_VAR), "false", "boolean");

        
        
        
        
        debugTestRunner.assertExpression(context, String.format("%s >= %s", INT_VAR, INT_VAR), "true", "boolean");
    }

    @Override
    @Test
    public void typeTestEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s is string", INT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s is int", INT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s is error", ERROR_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s is int | string", STRING_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s is 'Person_\\\\\\ \\/\\<\\>\\:\\@\\[\\`\\{\\~" +
                "\\u{03C0}_ƮέŞŢ", OBJECT_VAR), "true", "boolean");
        
    }

    @Override
    @Test
    public void equalityEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, "2.0==2.00", "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s==%s", INT_VAR, FLOAT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s==%s", OBJECT_VAR, ANON_OBJECT_VAR), "false",
                "boolean");
        debugTestRunner.assertExpression(context, "2.0!=2.00", "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!=%s", INT_VAR, FLOAT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!=%s", OBJECT_VAR, ANON_OBJECT_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, "2.0===2.00", "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s===%s", INT_VAR, FLOAT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s===%s", OBJECT_VAR, ANON_OBJECT_VAR), "false",
                "boolean");
        debugTestRunner.assertExpression(context, "2.0!==2.00", "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!==%s", INT_VAR, FLOAT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!==%s", OBJECT_VAR, ANON_OBJECT_VAR), "true",
                "boolean");
    }

    @Override
    @Test
    public void binaryBitwiseEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s & %s", INT_VAR, INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s | %s", INT_VAR, INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s ^ %s", INT_VAR, INT_VAR), "0", "int");
    }

    @Override
    @Test
    public void logicalEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s && false", BOOLEAN_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s || false", BOOLEAN_VAR), "true", "boolean");
    }

    @Override
    @Test
    public void conditionalExpressionEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s ? %s : %s", BOOLEAN_VAR, INT_VAR, FLOAT_VAR), "20",
                "int");
        
        debugTestRunner.assertExpression(context, String.format("%s ?: %s", INT_VAR, FLOAT_VAR), "20", "int");
        debugTestRunner.assertExpression(context, String.format("%s ?: %s", NIL_VAR, FLOAT_VAR), "-10.0", "float");
    }

    @Override
    @Test
    public void checkingExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void trapExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void queryExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void xmlNavigationEvaluationTest() throws BallerinaTestException {
        
    }

    @AfterClass(alwaysRun = true)
    public void cleanUp() {
        debugTestRunner.terminateDebugSession();
        this.context = null;
    }
}

Line commented on: debugTestRunner.assertExpression(context, ANON_FUNCTION_VAR, "function isolated function (string,string) " +

Revised code:
public void variableReferenceEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, NIL_VAR, "()", "nil");
        
        debugTestRunner.assertExpression(context, BOOLEAN_VAR, "true", "boolean");
        
        debugTestRunner.assertExpression(context, INT_VAR, "20", "int");
        
        debugTestRunner.assertExpression(context, FLOAT_VAR, "-10.0", "float");
        
        debugTestRunner.assertExpression(context, DECIMAL_VAR, "3.5", "decimal");
        
        debugTestRunner.assertExpression(context, STRING_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, XML_VAR, "<person " +
                "gender=\"male\"><firstname>Praveen</firstname><lastname>Nada</lastname></person>", "xml");
        
        debugTestRunner.assertExpression(context, ARRAY_VAR, "any[4]", "array");
        
        debugTestRunner.assertExpression(context, TUPLE_VAR, "tuple[int,string]", "tuple");
        
        debugTestRunner.assertExpression(context, MAP_VAR, "map", "map");
        
        debugTestRunner.assertExpression(context, RECORD_VAR, " /:@[`{~π_123_ƮέŞŢ_Student", "record");
        
        debugTestRunner.assertExpression(context, ANON_RECORD_VAR, "record {| string city; string country; |}",
                "record");
        
        debugTestRunner.assertExpression(context, ERROR_VAR, "SimpleErrorType", "error");
        
        debugTestRunner.assertExpression(context, ANON_FUNCTION_VAR, "function isolated function (string,string) " +
                                                 "returns (string)",
                "function");
        
        debugTestRunner.assertExpression(context, FUTURE_VAR, "future", "future");
        
        debugTestRunner.assertExpression(context, OBJECT_VAR, "Person_\\ /<>:@[`{~π_ƮέŞŢ", "object");
        
        debugTestRunner.assertExpression(context, TYPEDESC_VAR, "int", "typedesc");
        
        debugTestRunner.assertExpression(context, UNION_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, OPTIONAL_VAR, "foo", "string");
        
        debugTestRunner.assertExpression(context, ANY_VAR, "15.0", "float");
        
        debugTestRunner.assertExpression(context, ANYDATA_VAR, "619", "int");
        
        debugTestRunner.assertExpression(context, BYTE_VAR, "128", "int");
        
        debugTestRunner.assertExpression(context, TABLE_VAR, "table<Employee>[3]", "table");
        
        debugTestRunner.assertExpression(context, STREAM_VAR, "stream<int>", "stream");
        
        debugTestRunner.assertExpression(context, NEVER_VAR, "", "xml");
        
        debugTestRunner.assertExpression(context, JSON_VAR, "map<json>", "json");
        
        debugTestRunner.assertExpression(context, ANON_OBJECT_VAR, "Person_\\ /<>:@[`{~π_ƮέŞŢ", "object");

        
        
        
        debugTestRunner.assertExpression(context, GLOBAL_VAR_03, "map", "map");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_04, "()", "nil");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_05, "()", "nil");
        
        debugTestRunner.assertExpression(context, GLOBAL_VAR_06, "Ballerina", "string");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_07, "100.0", "decimal");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_08, "2", "int");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_09, "2.0", "float");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_10, "map<json>", "json");
        debugTestRunner.assertExpression(context, GLOBAL_VAR_11, "IL with global var", "string");

        
    }

    @Override
    @Test
    public void fieldAccessEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, OBJECT_VAR + ".address", "No 20, Palm grove", "string");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + ".'Ȧɢέ_\\ \\/\\:\\@\\[\\`\\{\\~π", "20", "int");
        
        debugTestRunner.assertExpression(context, JSON_VAR + ".name", "John", "string");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + ".grades.maths", "80", "int");
        
        debugTestRunner.assertExpression(context, RECORD_VAR + "?.undefined", "()", "nil");
    }

    @Override
    @Test
    public void xmlAttributeAccessEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void annotationAccessEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void memberAccessEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, STRING_VAR + "[0]", "f", "string");
        
        debugTestRunner.assertExpression(context, ARRAY_VAR + "[0]", "1", "int");
        
        
        
        
        
        
        
        
    }

    @Override
    @Test
    public void functionCallEvaluationTest() throws BallerinaTestException {

        

        
        
        debugTestRunner.assertExpression(context, " calculate ( 5 , 6 , 7 ) ;", "38", "int");

        
        
        debugTestRunner.assertExpression(context, "calculate ( 5 , c  =  7 , b  =  6 );", "38", "int");

        

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500)", "[2500, 20, 0.02]", "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, annualIncrement = 100)",
                "[2500, 100, 0.02]", "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, 100);", "[2500, 100, 0.02]", "string");

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, bonusRate = 0.1);", "[2500, 20, 0.1]",
                "string");

        
        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, 20, 0.1);", "[2500, 20, 0.1]", "string");

        
        
        debugTestRunner.assertExpression(context, "printSalaryDetails(2500, annualIncrement = 100, bonusRate = 0.1);",
                "[2500, 100, 0.1]", "string");

        
        
        
        debugTestRunner.assertExpression(context,
                "printSalaryDetails(annualIncrement = 100, baseSalary = 2500, bonusRate = 0.1);",
                "[2500, 100, 0.1]", "string");

        
        

        
        

        
        
        

        
        
        
        

        
        
        
        

        
        
        
        
    }

    @Override
    @Test
    public void methodCallEvaluationTest() throws BallerinaTestException {

        
        debugTestRunner.assertExpression(context, OBJECT_VAR + ".getSum(34,56)", "90", "int");

        

        
        debugTestRunner.assertExpression(context, ARRAY_VAR + ".length()", "4", "int");
        debugTestRunner.assertExpression(context, ARRAY_VAR + ".slice(1,3)", "any[2]", "array");

        
        
        debugTestRunner.assertExpression(context, DECIMAL_VAR + ".round()", "4", "decimal");
        debugTestRunner.assertExpression(context, DECIMAL_VAR + ".abs()", "3.5", "decimal");
        
        debugTestRunner.assertExpression(context, ERROR_VAR + ".message()", "SimpleErrorType", "string");
        
        debugTestRunner.assertExpression(context, FLOAT_VAR + ".sin()", "0.5440211108893698", "float");
        debugTestRunner.assertExpression(context, FLOAT_VAR + ".pow(3.0)", "-1000.0", "float");
        
        debugTestRunner.assertExpression(context, FUTURE_VAR + ".cancel()", "()", "nil");
        
        debugTestRunner.assertExpression(context, INT_VAR + ".abs()", "20", "int");
        
        debugTestRunner.assertExpression(context, MAP_VAR + ".get(\"country\")", "Sri Lanka", "string");
        
        
        
        
        debugTestRunner.assertExpression(context, STRING_VAR + ".getCodePoint(1)", "111", "int");
        debugTestRunner.assertExpression(context, STRING_VAR + ".substring(1,3)", "oo", "string");
        
        

        
        debugTestRunner.assertExpression(context, TYPEDESC_VAR + ".toBalString()", "typedesc int", "string");

        
        debugTestRunner.assertExpression(context, XML_VAR + ".getName()", "person", "string");
        debugTestRunner.assertExpression(context, XML_VAR + ".children()",
                "<firstname>Praveen</firstname><lastname>Nada</lastname>", "xml");
    }

    @Override
    @Test
    public void errorConstructorEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void anonymousFunctionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void letExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void typeCastEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("<float>%s", ANYDATA_VAR), "619.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("<float|boolean>%s", ANYDATA_VAR), "619.0", "float");
    }

    @Override
    @Test
    public void typeOfExpressionEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("typeof %s", BOOLEAN_VAR), "boolean", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s", INT_VAR), "int", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s", FLOAT_VAR), "float", "typedesc");
        
        debugTestRunner.assertExpression(context, String.format("typeof %s", JSON_VAR), "map<json>", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof %s[0]", STRING_VAR), "string", "typedesc");
        debugTestRunner.assertExpression(context, String.format("typeof typeof %s", BOOLEAN_VAR), "typedesc",
                "typedesc");
    }

    @Override
    @Test
    public void unaryExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("+%s", INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("+%s", FLOAT_VAR), "-10.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("+%s", DECIMAL_VAR), "3.5", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("-%s", INT_VAR), "-20", "int");
        
        debugTestRunner.assertExpression(context, String.format("-%s", FLOAT_VAR), "10.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("-%s", DECIMAL_VAR), "-3.5", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("~%s", INT_VAR), "-21", "int");

        
        
        debugTestRunner.assertExpression(context, String.format("!%s", BOOLEAN_VAR), "false", "boolean");
    }

    @Override
    @Test
    public void multiplicativeExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", INT_VAR, INT_VAR), "400", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", FLOAT_VAR, FLOAT_VAR), "100.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s * %s", DECIMAL_VAR, DECIMAL_VAR), "12.25",
                "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", INT_VAR, INT_VAR), "1", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", FLOAT_VAR, FLOAT_VAR), "1.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s / %s", DECIMAL_VAR, DECIMAL_VAR), "1", "decimal");

        
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", INT_VAR, INT_VAR), "0", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", FLOAT_VAR, FLOAT_VAR), "-0.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s %% %s", DECIMAL_VAR, DECIMAL_VAR), "0",
                "decimal");
    }

    @Override
    @Test
    public void additiveExpressionEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", INT_VAR, INT_VAR), "40", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", FLOAT_VAR, FLOAT_VAR), "-20.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s + %s", DECIMAL_VAR, DECIMAL_VAR), "7.0", "decimal");

        
        debugTestRunner.assertExpression(context, String.format("%s + %s", STRING_VAR, STRING_VAR), "foofoo", "string");
        
        debugTestRunner.assertExpression(context, "\" one \" + \" two \" + \" three \"", " one  two  three ", "string");
        
        String bStringTemplateExpr = String.format("string `name: ${%s}, age: ${%s}`", STRING_VAR, INT_VAR);
        debugTestRunner.assertExpression(context, String.format("%s + %s + %s", bStringTemplateExpr,
                bStringTemplateExpr, bStringTemplateExpr), "name: foo, age: 20name: foo, age: 20name: foo, age: 20",
                "string");

        
        debugTestRunner.assertExpression(context, String.format("%s + %s", XML_VAR, XML_VAR),
                "<person gender=\"male\">" +
                        "<firstname>Praveen</firstname><lastname>Nada</lastname></person><person gender=\"male\">" +
                        "<firstname>Praveen</firstname><lastname>Nada</lastname></person>", "xml");

        
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", INT_VAR, INT_VAR), "0", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", FLOAT_VAR, FLOAT_VAR), "0.0", "float");
        
        debugTestRunner.assertExpression(context, String.format("%s - %s", DECIMAL_VAR, DECIMAL_VAR), "0", "decimal");
    }

    @Override
    @Test
    public void shiftExpressionEvaluationTest() throws BallerinaTestException {
        debugTestRunner.assertExpression(context, String.format("%s << %s", INT_VAR, INT_VAR), "20971520", "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR), "-2000",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s << %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "2000", "int");

        debugTestRunner.assertExpression(context, String.format("%s >> %s", INT_VAR, INT_VAR), "0", "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "-1",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR), "-500",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >> %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR), "500",
                "int");

        debugTestRunner.assertExpression(context, String.format("%s >>> %s", INT_VAR, INT_VAR), "0", "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", SIGNED32INT_VAR, SIGNED8INT_VAR), "1",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", SIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "9223372036854775308",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", UNSIGNED32INT_VAR, SIGNED8INT_VAR), "0",
                "int");
        debugTestRunner.assertExpression(context, String.format("%s >>> %s", UNSIGNED32INT_VAR, UNSIGNED8INT_VAR),
                "500", "int");
    }

    @Override
    @Test
    public void rangeExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void comparisonEvaluationTest() throws BallerinaTestException {
        
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", NIL_VAR, NIL_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", BOOLEAN_VAR, BOOLEAN_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", INT_VAR, INT_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", FLOAT_VAR, FLOAT_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", DECIMAL_VAR, DECIMAL_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", STRING_VAR, STRING_VAR), "false",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "booleanArrayVar", "booleanArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "intArrayVar", "intArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "floatArrayVar", "floatArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "decimalArrayVar", "decimalArrayVar"),
                "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s < %s", "stringArrayVar", "stringArrayVar"),
                "false", "boolean");

        
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", NIL_VAR, NIL_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", BOOLEAN_VAR, BOOLEAN_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", INT_VAR, INT_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", FLOAT_VAR, FLOAT_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", DECIMAL_VAR, DECIMAL_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", STRING_VAR, STRING_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "booleanArrayVar", "booleanArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "intArrayVar", "intArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "floatArrayVar", "floatArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "decimalArrayVar", "decimalArrayVar"),
                "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s <= %s", "stringArrayVar", "stringArrayVar"),
                "true", "boolean");

        
        
        
        
        debugTestRunner.assertExpression(context, String.format("%s > %s", INT_VAR, INT_VAR), "false", "boolean");

        
        
        
        
        debugTestRunner.assertExpression(context, String.format("%s >= %s", INT_VAR, INT_VAR), "true", "boolean");
    }

    @Override
    @Test
    public void typeTestEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s is string", INT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s is int", INT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s is error", ERROR_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s is int | string", STRING_VAR), "true", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s is 'Person_\\\\\\ \\/\\<\\>\\:\\@\\[\\`\\{\\~" +
                "\\u{03C0}_ƮέŞŢ", OBJECT_VAR), "true", "boolean");
        
    }

    @Override
    @Test
    public void equalityEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, "2.0==2.00", "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s==%s", INT_VAR, FLOAT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s==%s", OBJECT_VAR, ANON_OBJECT_VAR), "false",
                "boolean");
        debugTestRunner.assertExpression(context, "2.0!=2.00", "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!=%s", INT_VAR, FLOAT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!=%s", OBJECT_VAR, ANON_OBJECT_VAR), "true",
                "boolean");
        
        debugTestRunner.assertExpression(context, "2.0===2.00", "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s===%s", INT_VAR, FLOAT_VAR), "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s===%s", OBJECT_VAR, ANON_OBJECT_VAR), "false",
                "boolean");
        debugTestRunner.assertExpression(context, "2.0!==2.00", "false", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!==%s", INT_VAR, FLOAT_VAR), "true", "boolean");
        debugTestRunner.assertExpression(context, String.format("%s!==%s", OBJECT_VAR, ANON_OBJECT_VAR), "true",
                "boolean");
    }

    @Override
    @Test
    public void binaryBitwiseEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s & %s", INT_VAR, INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s | %s", INT_VAR, INT_VAR), "20", "int");
        
        debugTestRunner.assertExpression(context, String.format("%s ^ %s", INT_VAR, INT_VAR), "0", "int");
    }

    @Override
    @Test
    public void logicalEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s && false", BOOLEAN_VAR), "false", "boolean");
        
        debugTestRunner.assertExpression(context, String.format("%s || false", BOOLEAN_VAR), "true", "boolean");
    }

    @Override
    @Test
    public void conditionalExpressionEvaluationTest() throws BallerinaTestException {
        
        debugTestRunner.assertExpression(context, String.format("%s ? %s : %s", BOOLEAN_VAR, INT_VAR, FLOAT_VAR), "20",
                "int");
        
        debugTestRunner.assertExpression(context, String.format("%s ?: %s", INT_VAR, FLOAT_VAR), "20", "int");
        debugTestRunner.assertExpression(context, String.format("%s ?: %s", NIL_VAR, FLOAT_VAR), "-10.0", "float");
    }

    @Override
    @Test
    public void checkingExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void trapExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void queryExpressionEvaluationTest() throws BallerinaTestException {
        
    }

    @Override
    @Test
    public void xmlNavigationEvaluationTest() throws BallerinaTestException {
        
    }

    @AfterClass(alwaysRun = true)
    public void cleanUp() {
        debugTestRunner.terminateDebugSession();
        this.context = null;
    }
}