summaryrefslogtreecommitdiff
path: root/java/typeMigration/testData/refactoring/typeMigration/t03
diff options
context:
space:
mode:
Diffstat (limited to 'java/typeMigration/testData/refactoring/typeMigration/t03')
-rw-r--r--java/typeMigration/testData/refactoring/typeMigration/t03/after/Test.items10
-rw-r--r--java/typeMigration/testData/refactoring/typeMigration/t03/after/test.java22
-rw-r--r--java/typeMigration/testData/refactoring/typeMigration/t03/before/test.java22
3 files changed, 54 insertions, 0 deletions
diff --git a/java/typeMigration/testData/refactoring/typeMigration/t03/after/Test.items b/java/typeMigration/testData/refactoring/typeMigration/t03/after/Test.items
new file mode 100644
index 000000000000..f1747c90b2ed
--- /dev/null
+++ b/java/typeMigration/testData/refactoring/typeMigration/t03/after/Test.items
@@ -0,0 +1,10 @@
+Types:
+PsiMethod:sum : java.lang.Integer
+PsiMethodCallExpression:sum(i, k) : java.lang.Integer
+
+Conversions:
+a -> $
+i + j -> $
+
+New expression type changes:
+Fails:
diff --git a/java/typeMigration/testData/refactoring/typeMigration/t03/after/test.java b/java/typeMigration/testData/refactoring/typeMigration/t03/after/test.java
new file mode 100644
index 000000000000..5fd61417ba05
--- /dev/null
+++ b/java/typeMigration/testData/refactoring/typeMigration/t03/after/test.java
@@ -0,0 +1,22 @@
+/**
+ * Created by IntelliJ IDEA.
+ * User: db
+ * Date: Nov 15, 2004
+ * Time: 5:40:02 PM
+ * To change this template use File | Settings | File Templates.
+ */
+public class Test {
+ Integer sum(int i, int j) {
+ return i + j;
+ }
+
+ int[] foo(int n, int k) {
+ int[] a = new int[n];
+
+ for (int i = 0; i < a.length; i++) {
+ a[i] = sum(i, k);
+ }
+
+ return a;
+ }
+}
diff --git a/java/typeMigration/testData/refactoring/typeMigration/t03/before/test.java b/java/typeMigration/testData/refactoring/typeMigration/t03/before/test.java
new file mode 100644
index 000000000000..9e1559784bde
--- /dev/null
+++ b/java/typeMigration/testData/refactoring/typeMigration/t03/before/test.java
@@ -0,0 +1,22 @@
+/**
+ * Created by IntelliJ IDEA.
+ * User: db
+ * Date: Nov 15, 2004
+ * Time: 5:40:02 PM
+ * To change this template use File | Settings | File Templates.
+ */
+public class Test {
+ int sum(int i, int j) {
+ return i + j;
+ }
+
+ int[] foo(int n, int k) {
+ int[] a = new int[n];
+
+ for (int i = 0; i < a.length; i++) {
+ a[i] = sum(i, k);
+ }
+
+ return a;
+ }
+}