added some tests
Some checks are pending
Gitea Actions Demo / Explore-Gitea-Actions (push) Waiting to run

This commit is contained in:
Bruder John 2024-07-01 12:58:24 +02:00
parent f3e3158460
commit 36e56fa66e
4 changed files with 69 additions and 0 deletions

View File

@ -0,0 +1,13 @@
// @expected: TypeMismatchException
public class Test{
public void test(boolean b){
if(b == 2){
} else {
}
}
}

View File

@ -0,0 +1,19 @@
public class Test{
public Car c;
public int test(){
return c.getSpeed();
}
}
public class Car{
private int speed;
public int getSpeed(){
return speed;
}
}

View File

@ -0,0 +1,12 @@
public class Test{
public void test(boolean b){
if(b == true){
} else {
}
}
}

View File

@ -0,0 +1,25 @@
public class Test {
public Car c;
public int test(boolean b, int x) {
if (b == true) {
return c.getSpeed();
} else {
return x;
}
}
}
public class Car {
private int speed;
public int getSpeed() {
return speed;
}
}