Safe Delete: Move test classes and test data to refactoring directory

This commit is contained in:
Alexey Sedunov
2015-12-08 16:32:16 +03:00
parent a76f43b66c
commit ffc8b6fd89
504 changed files with 229 additions and 229 deletions
@@ -0,0 +1,7 @@
package test;
public class A {
public void usage(RemData p) {
System.out.println(p.component1());
}
}
@@ -0,0 +1,3 @@
package test
data public class RemData(val remo<caret>vable: Int)
@@ -0,0 +1 @@
parameter removable has 1 usage that is not safe to delete.
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(1, 2)
}
void bar(C c) {
c.foo(1, 2)
}
void bar(D d) {
d.foo(1, 2)
}
void bar(Z z) {
z.foo(1, 2)
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(2)
}
void bar(C c) {
c.foo(2)
}
void bar(D d) {
d.foo(2)
}
void bar(Z z) {
z.foo(2)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(<caret>a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(b: Int)
}
open class A {
open fun foo(b: Int) {
}
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
class D: B(), Z {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(1, 2)
}
void bar(C c) {
c.foo(1, 2)
}
void bar(D d) {
d.foo(1, 2)
}
void bar(Z z) {
z.foo(1, 2)
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(2)
}
void bar(C c) {
c.foo(2)
}
void bar(D d) {
d.foo(2)
}
void bar(Z z) {
z.foo(2)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(<caret>a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(b: Int)
}
open class A {
open fun foo(b: Int) {
}
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
class D: B(), Z {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(1, 2)
}
void bar(C c) {
c.foo(1, 2)
}
void bar(D d) {
d.foo(1, 2)
}
void bar(Z z) {
z.foo(1, 2)
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(2)
}
void bar(C c) {
c.foo(2)
}
void bar(D d) {
d.foo(2)
}
void bar(Z z) {
z.foo(2)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(<caret>a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(b: Int)
}
open class A {
open fun foo(b: Int) {
}
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
class D: B(), Z {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(1, 2)
}
void bar(C c) {
c.foo(1, 2)
}
void bar(D d) {
d.foo(1, 2)
}
void bar(Z z) {
z.foo(1, 2)
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(2)
}
void bar(C c) {
c.foo(2)
}
void bar(D d) {
d.foo(2)
}
void bar(Z z) {
z.foo(2)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(<caret>a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(b: Int)
}
open class A {
open fun foo(b: Int) {
}
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
class D: B(), Z {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(1, 2)
}
void bar(C c) {
c.foo(1, 2)
}
void bar(D d) {
d.foo(1, 2)
}
void bar(Z z) {
z.foo(1, 2)
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(2)
}
void bar(C c) {
c.foo(2)
}
void bar(D d) {
d.foo(2)
}
void bar(Z z) {
z.foo(2)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(<caret>a: Int, b: Int) {
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(b: Int)
}
open class A {
open fun foo(b: Int) {
}
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
class D: B(), Z {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,29 @@
interface Z {
open fun foo(<caret>a: Int, b: Int) {
println(a)
}
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(<caret>a: Int, b: Int) {
println(a)
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(<caret>a: Int, b: Int) {
println(a)
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(<caret>a: Int, b: Int) {
println(a)
}
}
class D: B(), Z {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,21 @@
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,27 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class A {
open fun foo(a: Int, b: Int) {
}
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
class D: B(), Z {
override fun foo(<caret>a: Int, b: Int) {
println(a)
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1", "!")
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(<caret>a: Int, b: String, c: Any) {
println(a)
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1", "!")
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo("1", "!")
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(<caret>a: Int, b: String, c: Any) {
println(b)
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(b: String, c: Any) {
println(b)
}
}
@@ -0,0 +1,13 @@
package test;
class A {
void bar() {
LambdaArgKt.foo(
10, new Function1<Integer, Unit>() {
public Unit invoke(Integer n) {
System.out.println(n);
}
}
);
}
}
@@ -0,0 +1,9 @@
package test;
class A {
void bar() {
LambdaArgKt.foo(
10
);
}
}
@@ -0,0 +1,9 @@
package test
fun foo(n: Int, <caret>f: (Int) -> Unit) {
println(n)
}
fun bar() {
foo(10) { n -> println(n) }
}
@@ -0,0 +1,9 @@
package test
fun foo(n: Int) {
println(n)
}
fun bar() {
foo(10)
}
@@ -0,0 +1,13 @@
package test;
class A {
void bar() {
LambdaArgExtKt.foo(
"", 10, new Function1<Integer, Unit>() {
public Unit invoke(Integer n) {
System.out.println(n);
}
}
);
}
}
@@ -0,0 +1,9 @@
package test;
class A {
void bar() {
LambdaArgExtKt.foo(
"", 10
);
}
}
@@ -0,0 +1,9 @@
package test
fun String.foo(n: Int, <caret>f: (Int) -> Unit) {
println(n)
}
fun bar() {
"".foo(10) { n -> println(n) }
}
@@ -0,0 +1,9 @@
package test
fun String.foo(n: Int) {
println(n)
}
fun bar() {
"".foo(10)
}
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
}
}
class D extends B implements Z {
public void foo(int a, int b) {
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int b) {
}
}
class D extends B implements Z {
public void foo(int b) {
}
}
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(4)
}
void bar(C c) {
c.foo(6)
}
void bar(D d) {
d.foo(8)
}
void bar(Z z) {
z.foo(10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(<caret>a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(b: Int)
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
}
}
class D extends B implements Z {
public void foo(int a, int b) {
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int b) {
}
}
class D extends B implements Z {
public void foo(int b) {
}
}
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(4)
}
void bar(C c) {
c.foo(6)
}
void bar(D d) {
d.foo(8)
}
void bar(Z z) {
z.foo(10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(<caret>a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(b: Int)
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
}
}
class D extends B implements Z {
public void foo(int a, int b) {
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int b) {
}
}
class D extends B implements Z {
public void foo(int b) {
}
}
class U {
void bar(A a) {
a.foo(2)
}
void bar(B b) {
b.foo(4)
}
void bar(C c) {
c.foo(6)
}
void bar(D d) {
d.foo(8)
}
void bar(Z z) {
z.foo(10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(<caret>a: Int, b: Int) {
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(b: Int)
}
open class B: A(), Z {
override fun foo(b: Int) {
}
}
class C: A() {
override fun foo(b: Int) {
}
}
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
System.out.println(a);
}
}
class D extends B implements Z {
public void foo(int a, int b) {
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(<caret>a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
}
}
class D extends B implements Z {
public void foo(int a, int b) {
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(<caret>a: Int, b: Int) {
}
}
class C: A() {
override fun foo(a: Int, b: Int) {
println(a)
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,33 @@
class A {
public void foo(int a, int b) {
}
}
class D extends B implements Z {
public void foo(int a, int b) {
System.out.println(a);
}
}
class U {
void bar(A a) {
a.foo(1, 2)
}
void bar(B b) {
b.foo(3, 4)
}
void bar(C c) {
c.foo(5, 6)
}
void bar(D d) {
d.foo(7, 8)
}
void bar(Z z) {
z.foo(9, 10)
}
}
@@ -0,0 +1,15 @@
interface Z {
open fun foo(a: Int, b: Int)
}
open class B: A(), Z {
override fun foo(a: Int, b: Int) {
}
}
class C: A() {
override fun foo(<caret>a: Int, b: Int) {
}
}
@@ -0,0 +1 @@
parameter a has 1 usage that is not safe to delete.
@@ -0,0 +1,7 @@
package test;
class B {
void bar() {
System.out.println(new A("").getName());
}
}
@@ -0,0 +1,7 @@
package test
class A(val <caret>name: String)
fun bar() {
println(A("").name)
}
@@ -0,0 +1 @@
parameter name has 2 usages that are not safe to delete.
@@ -0,0 +1,7 @@
package test;
class B {
void bar() {
System.out.println(new A(""));
}
}
@@ -0,0 +1,7 @@
package test;
class B {
void bar() {
System.out.println(new A());
}
}
@@ -0,0 +1,7 @@
package test
class A(val <caret>name: String)
fun bar() {
println(A(""))
}
@@ -0,0 +1,7 @@
package test
class A()
fun bar() {
println(A())
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1", "!")
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo("1", "!")
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(<caret>a: Int, b: String, c: Any) {
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(b: String, c: Any) {
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1", "!")
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "!")
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(a: Int, <caret>b: String, c: Any) {
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(a: Int, c: Any) {
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1", "!")
}
}
@@ -0,0 +1,5 @@
class B {
void bar(A a) {
a.foo(1, "1")
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(a: Int, b: String, <caret>c: Any) {
}
}
@@ -0,0 +1,5 @@
class A {
fun foo(a: Int, b: String) {
}
}
@@ -0,0 +1,7 @@
package test;
class B {
void bar(A a) {
SafeUsagesExt1Kt.foo(a, 1, "1", "!");
}
}
@@ -0,0 +1,7 @@
package test;
class B {
void bar(A a) {
SafeUsagesExt1Kt.foo(a, "1", "!");
}
}
@@ -0,0 +1,9 @@
package test
class A {
}
fun A.foo(<caret>a: Int, b: String, c: Any) {
}
@@ -0,0 +1,9 @@
package test
class A {
}
fun A.foo(b: String, c: Any) {
}
@@ -0,0 +1,7 @@
package test;
class B {
void bar(A a) {
SafeUsagesExt2Kt.foo(a, 1, "1", "!");
}
}
@@ -0,0 +1,7 @@
package test;
class B {
void bar(A a) {
SafeUsagesExt2Kt.foo(a, 1, "!");
}
}
@@ -0,0 +1,9 @@
package test
class A {
}
fun A.foo(a: Int, <caret>b: String, c: Any) {
}

Some files were not shown because too many files have changed in this diff Show More