use of org.ballerinalang.launcher.util.CompileResult in project ballerina by ballerina-lang.
the class TaintedStatusPropagationTest method testTupleReturn.
@Test
public void testTupleReturn() {
CompileResult result = BCompileUtil.compile("test-src/taintchecking/propagation/tuple-return.bal");
Assert.assertTrue(result.getDiagnostics().length == 0);
}
use of org.ballerinalang.launcher.util.CompileResult in project ballerina by ballerina-lang.
the class TaintedStatusPropagationTest method testStringTemplate.
@Test
public void testStringTemplate() {
CompileResult result = BCompileUtil.compile("test-src/taintchecking/propagation/string-template.bal");
Assert.assertTrue(result.getDiagnostics().length == 0);
}
use of org.ballerinalang.launcher.util.CompileResult in project ballerina by ballerina-lang.
the class TaintedStatusPropagationTest method testArray.
@Test
public void testArray() {
CompileResult result = BCompileUtil.compile("test-src/taintchecking/propagation/array.bal");
Assert.assertTrue(result.getDiagnostics().length == 0);
}
use of org.ballerinalang.launcher.util.CompileResult in project ballerina by ballerina-lang.
the class TaintedStatusPropagationTest method testWithoutUserDataNegative.
@Test
public void testWithoutUserDataNegative() {
CompileResult result = BCompileUtil.compile("test-src/taintchecking/propagation/without-user-data-negative.bal");
Assert.assertTrue(result.getDiagnostics().length == 1);
BAssertUtil.validateError(result, 0, "tainted value passed to sensitive parameter 'secureIn'", 7, 20);
}
use of org.ballerinalang.launcher.util.CompileResult in project ballerina by ballerina-lang.
the class TaintedStatusPropagationTest method testChainedInvocationsNegative.
@Test
public void testChainedInvocationsNegative() {
CompileResult result = BCompileUtil.compile("test-src/taintchecking/propagation/chained-invocations-negative.bal");
Assert.assertTrue(result.getDiagnostics().length == 1);
BAssertUtil.validateError(result, 0, "tainted value passed to sensitive parameter 'secureIn'", 2, 20);
}
Aggregations