moving tests to CE

This commit is contained in:
Dmitry Jemerov
2009-09-25 21:28:29 +04:00
parent 612966f758
commit 4c0f33ef3b
9 changed files with 6 additions and 0 deletions
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<problems>
<problem>
<file>Assignment.java</file>
<line>4</line>
<description>'x' should probably not be assigned to 'y'</description>
</problem>
</problems>
@@ -0,0 +1,6 @@
public class Assignment {
public void test() {
int x = 0, y = 0;
y = x;
}
}
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<problems>
<problem>
<file>Initializer.java</file>
<line>4</line>
<description>'x' should probably not be assigned to 'y'</description>
</problem>
</problems>
@@ -0,0 +1,6 @@
public class Initializer {
public void test() {
int x = 0;
int y = x;
}
}
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<problems>
<problem>
<file>Parameter.java</file>
<line>4</line>
<description>'startX' should probably not be passed as parameter 'y'</description>
</problem>
</problems>
@@ -0,0 +1,9 @@
public class Parameter {
public void test() {
int startX = 0;
method(startX);
}
private void method(int y) {
}
}
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<problems>
<problem>
<file>ReturnValue.java</file>
<line>4</line>
<description>'y' should probably not be returned from method 'getX'</description>
</problem>
</problems>
@@ -0,0 +1,6 @@
public class ReturnValue {
public int getX() {
int y=0;
return y;
}
}