Refactor debugger tests

1. Move tests to their own module
2. Avoid sharing the 'tinyApp' project between tests
3. Clean up option directive handling
This commit is contained in:
Yan Zhulanow
2019-06-26 22:41:56 +09:00
parent d8d81c51d7
commit 472ec72eb9
288 changed files with 4861 additions and 3910 deletions
@@ -1,3 +1,4 @@
// FILE: text.kt
package isInsideInlineLambda
fun main(args: Array<String>) {
@@ -73,3 +74,46 @@ class A {
// ADDITIONAL_BREAKPOINT: isInsideInlineLambdaInLibrary.kt:Breakpoint5:(1)
// EXPRESSION: it + 15
// RESULT: 20: I
// FILE: isInsideInlineLambdaInLibrary.kt
package isInsideInlineLambdaInLibrary
public fun test() {
val a = A()
//Breakpoint1
a.foo(1) { 1 }
// inside other lambda
a.foo(100) {
//Breakpoint2
a.foo(2) { 1 }
1
}
// inside variable declaration
//Breakpoint3
val x = a.foo(3) { 1 }
// inside object declaration
val y = object {
fun foo() {
//Breakpoint4
a.foo(4) { 1 }
}
}
y.foo()
// inside local function
fun local() {
//Breakpoint5
a.foo(5) { 1 }
}
local()
}
class A {
inline fun foo(i: Int, f: (i: Int) -> Int): A {
f(i)
return this
}
}
@@ -1,34 +1,34 @@
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:6 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:11 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:17 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:23 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:31 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambda.kt:9 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambda.kt:17 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambda.kt:25 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambda.kt:33 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambda.kt:43 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:7 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:12 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:18 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:24 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:32 lambdaOrdinal = 1
LineBreakpoint created at text.kt:10 lambdaOrdinal = 1
LineBreakpoint created at text.kt:18 lambdaOrdinal = 1
LineBreakpoint created at text.kt:26 lambdaOrdinal = 1
LineBreakpoint created at text.kt:34 lambdaOrdinal = 1
LineBreakpoint created at text.kt:44 lambdaOrdinal = 1
Run Java
Connected to the target VM
isInsideInlineLambda.kt:9
text.kt:10
Compile bytecode for it + 1
isInsideInlineLambda.kt:17
text.kt:18
Compile bytecode for it + 2
isInsideInlineLambda.kt:25
text.kt:26
Compile bytecode for it + 3
isInsideInlineLambda.kt:33
text.kt:34
Compile bytecode for it + 4
isInsideInlineLambda.kt:43
text.kt:44
Compile bytecode for it + 5
isInsideInlineLambdaInLibrary.kt:6
isInsideInlineLambdaInLibrary.kt:7
Compile bytecode for it + 11
isInsideInlineLambdaInLibrary.kt:11
isInsideInlineLambdaInLibrary.kt:12
Compile bytecode for it + 12
isInsideInlineLambdaInLibrary.kt:17
isInsideInlineLambdaInLibrary.kt:18
Compile bytecode for it + 13
isInsideInlineLambdaInLibrary.kt:23
isInsideInlineLambdaInLibrary.kt:24
Compile bytecode for it + 14
isInsideInlineLambdaInLibrary.kt:31
isInsideInlineLambdaInLibrary.kt:32
Compile bytecode for it + 15
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: customLibClassName.kt
package customLibClassName
fun main(args: Array<String>) {
@@ -26,4 +27,87 @@ fun main(args: Array<String>) {
// ADDITIONAL_BREAKPOINT: simpleLibFile.kt:public fun foo() {
// EXPRESSION: 1 + 5
// RESULT: 6: I
// RESULT: 6: I
// FILE: lib/oneFunSameClassName/1/a1.kt
@file:JvmName("SameNameOneFunSameFileName")
@file:JvmMultifileClass
package customLib.oneFunSameClassName
public fun oneFunSameFileNameFun(): Int {
return 1
}
// FILE: lib/oneFunSameClassName/2/a2.kt
@file:JvmName("SameNameOneFunSameFileName")
@file:JvmMultifileClass
package customLib.oneFunSameClassName
public fun oneFunSameFileNameFun2(): Int {
return 1
}
// FILE: lib/twoFunDifferentSignature/1/a1.kt
@file:JvmName("SameNameTwoFunDifferentSignature")
@file:JvmMultifileClass
package customLib.twoFunDifferentSignature
public fun twoFunDifferentSignatureFun(): Int {
return 1
}
// FILE: lib/twoFunDifferentSignature/2/a2.kt
@file:JvmName("SameNameTwoFunDifferentSignature")
@file:JvmMultifileClass
package customLib.twoFunDifferentSignature
public fun twoFunDifferentSignatureFun(i: Int): Int {
return 1
}
// FILE: lib/breakpointOnLocalProperty/1/a1.kt
@file:JvmName("SameNameBreakpointOnLocalProperty")
@file:JvmMultifileClass
package customLib.breakpointOnLocalProperty
public fun breakpointOnLocalPropertyFun(): Int {
val a = 1
return 1
}
// FILE: lib/breakpointOnLocalProperty/2/a2.kt
@file:JvmName("SameNameBreakpointOnLocalProperty")
@file:JvmMultifileClass
package customLib.breakpointOnLocalProperty
public fun breakpointOnLocalPropertyFun2(): Int {
return 1
}
// FILE: lib/property/1/a1.kt
@file:JvmName("SameNameProperty")
@file:JvmMultifileClass
package customLib.property
public val foo: Int =
1
// FILE: lib/property/2/a2.kt
@file:JvmName("SameNameProperty")
@file:JvmMultifileClass
package customLib.property
public fun someFun(): Int {
return 1
}
// FILE: lib/simpleLibFile/simpleLibFile.kt
package customLib.simpleLibFile
public fun foo() {
1 + 1
}
class B {
public var prop: Int = 1
}
@@ -1,19 +1,19 @@
LineBreakpoint created at a1.kt:6
LineBreakpoint created at a1.kt:6
LineBreakpoint created at a1.kt:6
LineBreakpoint created at a1.kt:6
LineBreakpoint created at simpleLibFile.kt:4
LineBreakpoint created at a1.kt:7
LineBreakpoint created at a1.kt:7
LineBreakpoint created at a1.kt:7
LineBreakpoint created at a1.kt:7
LineBreakpoint created at simpleLibFile.kt:5
Run Java
Connected to the target VM
a1.kt:6
a1.kt:7
Compile bytecode for 1 + 1
a1.kt:6
a1.kt:7
Compile bytecode for 1 + 2
a1.kt:6
a1.kt:7
Compile bytecode for 1 + 3
a1.kt:6
a1.kt:7
Compile bytecode for 1 + 4
simpleLibFile.kt:4
simpleLibFile.kt:5
Compile bytecode for 1 + 5
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: test.kt
package localFunInLibrary
fun main(args: Array<String>) {
@@ -6,4 +7,12 @@ fun main(args: Array<String>) {
// ADDITIONAL_BREAKPOINT: localFunCustomLib.kt:localFunInLibraryCustomLibProperty
// EXPRESSION: localFun()
// RESULT: 1: I
// RESULT: 1: I
// FILE: localFunCustomLib.kt
package customLib.localFunInLibraryCustomLib
public fun localFunInLibraryCustomLibMainFun() {
fun localFun() = 1
val localFunInLibraryCustomLibProperty = 1
}
@@ -1,7 +1,7 @@
LineBreakpoint created at localFunCustomLib.kt:6
LineBreakpoint created at localFunCustomLib.kt:7
Run Java
Connected to the target VM
localFunCustomLib.kt:6
localFunCustomLib.kt:7
Compile bytecode for localFun()
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: breakpointInInlineFun.kt
package breakpointInInlineFun
import customLib.inlineFunInLibrary.*
@@ -9,4 +10,19 @@ fun main(args: Array<String>) {
// RESUME: 2
// ADDITIONAL_BREAKPOINT: inlineFunInLibrary.kt:public inline fun inlineFun
// ADDITIONAL_BREAKPOINT: inlineFunInLibrary.kt: Breakpoint 2
// ADDITIONAL_BREAKPOINT: inlineFunInLibrary.kt: Breakpoint 2
// FILE: customLib/inlineFunInLibrary/inlineFunInLibrary.kt
package customLib.inlineFunInLibrary
public inline fun inlineFun(f: () -> Unit) {
1 + 1
inlineFunInner {
1 + 1
}
}
public inline fun inlineFunInner(f: () -> Unit) {
// Breakpoint 2
1 + 1
}
@@ -1,9 +1,9 @@
LineBreakpoint created at inlineFunInLibrary.kt:4
LineBreakpoint created at inlineFunInLibrary.kt:12
LineBreakpoint created at inlineFunInLibrary.kt:5
LineBreakpoint created at inlineFunInLibrary.kt:13
Run Java
Connected to the target VM
inlineFunInLibrary.kt:4
inlineFunInLibrary.kt:12
inlineFunInLibrary.kt:5
inlineFunInLibrary.kt:13
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: classFromAnotherPackage.kt
package classFromAnotherPackage
import forTests.MyJavaClass
@@ -12,3 +13,7 @@ fun main(args: Array<String>) {
// EXPRESSION: forTests.MyJavaClass()
// RESULT: instance of forTests.MyJavaClass(id=ID): LforTests/MyJavaClass;
// FILE: forTests/MyJavaClass.java
package forTests;
public class MyJavaClass {}
@@ -1,7 +1,7 @@
LineBreakpoint created at classFromAnotherPackage.kt:7
LineBreakpoint created at classFromAnotherPackage.kt:8
Run Java
Connected to the target VM
classFromAnotherPackage.kt:7
classFromAnotherPackage.kt:8
Compile bytecode for MyJavaClass()
Compile bytecode for forTests.MyJavaClass()
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: createExpressionWithArray.kt
package createExpressionWithArray
import forTests.MyJavaClass
@@ -13,3 +14,28 @@ fun main(args: Array<String>) {
// PRINT_FRAME
// DESCRIPTOR_VIEW_OPTIONS: NAME_EXPRESSION_RESULT
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
import java.util.List;
public class MyJavaClass {
public static class BaseClass {
public final int i2 = 1;
}
public BaseClass getBaseClassValue() {
return new BaseClass();
}
public BaseClass getInnerClassValue() {
return new InnerClass();
}
public static class InnerClass extends BaseClass {
public final int i = 1;
}
public MyJavaClass() {}
}
@@ -1,7 +1,7 @@
LineBreakpoint created at createExpressionWithArray.kt:11
LineBreakpoint created at createExpressionWithArray.kt:12
Run Java
Connected to the target VM
createExpressionWithArray.kt:11
createExpressionWithArray.kt:12
Compile bytecode for args
Compile bytecode for baseArray
Compile bytecode for baseArray[0]
@@ -1,3 +1,4 @@
// FILE: delegatedPropertyInOtherFile.kt
package delegatedPropertyInOtherFile
import delegatedPropertyInOtherFileOther.*
@@ -11,3 +12,16 @@ fun main(a: Array<String>) {
// EXPRESSION: t.a
// RESULT: 12: I
// FILE: delegatedPropertyInOtherFile/delegatedPropertyInOtherFile2.kt
package delegatedPropertyInOtherFileOther
import kotlin.reflect.KProperty
class WithDelegate {
val a: Int by Id(12)
}
class Id(val v: Int) {
operator fun getValue(o: Any, property: KProperty<*>): Int = v
}
@@ -1,7 +1,7 @@
LineBreakpoint created at delegatedPropertyInOtherFile.kt:9
LineBreakpoint created at delegatedPropertyInOtherFile.kt:10
Run Java
Connected to the target VM
delegatedPropertyInOtherFile.kt:9
delegatedPropertyInOtherFile.kt:10
Compile bytecode for t.a
Disconnected from the target VM
@@ -2,7 +2,6 @@ LineBreakpoint created at evDelegatedProperty.kt:13
Run Java
Connected to the target VM
evDelegatedProperty.kt:13
Compile bytecode for a.prop
frame = main:13, EvDelegatedPropertyKt {evDelegatedProperty}
local = args: java.lang.String[] = {java.lang.String[0]@uniqueID} (sp = evDelegatedProperty.kt, 9)
local = a: evDelegatedProperty.A = {evDelegatedProperty.A@uniqueID} (sp = evDelegatedProperty.kt, 10)
@@ -1,3 +1,4 @@
// FILE: fieldGetters.kt
package fieldGetters
import forTests.FieldsGetters
@@ -30,8 +31,6 @@ class K2 {
// EXPRESSION: K2().a_field
// RESULT: 0: I
// EXPRESSION: PublicField().foo
// RESULT: "a": Ljava/lang/String;
@@ -102,4 +101,82 @@ class K2 {
// RESULT: "a": Ljava/lang/String;
// EXPRESSION: PublicFieldAndGetterInParent().foo_field
// RESULT: "b": Ljava/lang/String;
// RESULT: "b": Ljava/lang/String;
// FILE: forTests/FieldsGetters.java
package forTests;
public class FieldsGetters {
public static class PublicField {
public String foo = "a";
}
public static class PackagePrivateField {
String foo = "b";
}
public static class ProtectedField {
protected String foo = "c";
}
public static class PrivateField {
private String foo = "d";
}
public static class PublicFieldGetter {
public final String foo = "a";
public String getFoo() {
return "b";
}
}
public static class PrivateFieldPublicGetter {
private final String foo = "c";
public String getFoo() {
return "d";
}
}
public static class PrivateFieldPrivateGetter {
private final String foo = "e";
public String getFoo() {
return "f";
}
}
public static class PublicGetter1 extends PublicField {
public String getFoo() {
return "g";
}
}
public static class PublicGetter2 extends PackagePrivateField {
public String getFoo() {
return "h";
}
}
public static class PrivateGetter1 extends PrivateField {
private String getFoo() {
return "g";
}
}
public static class PublicGetterOnly {
public String getFoo() {
return "a";
}
}
public static class PublicFieldAndGetterInParent extends PublicGetterOnly {
public String foo = "b";
}
public abstract class AbstractGetter {
public String foo = "c";
public abstract String getFoo();
}
}
@@ -1,7 +1,7 @@
LineBreakpoint created at fieldGetters.kt:8
LineBreakpoint created at fieldGetters.kt:9
Run Java
Connected to the target VM
fieldGetters.kt:8
fieldGetters.kt:9
Compile bytecode for K1().a
Compile bytecode for K1().a_field
Compile bytecode for K2().a
@@ -1,3 +1,4 @@
// FILE: fileWithError.kt
package fileWithError
fun main(args: Array<String>) {
@@ -8,4 +9,17 @@ fun main(args: Array<String>) {
// ADDITIONAL_BREAKPOINT: fileWithInternal.kt:Breakpoint
// EXPRESSION: 1
// RESULT: 1: I
// RESULT: 1: I
// FILE: lib/fileWithInternal.kt
package fileWithInternal
fun test() {
// Breakpoint
val a = fileWithInternal2.MyInternal()
}
// FILE: lib/fileWithInternal2.kt
package fileWithInternal2
internal class MyInternal
@@ -1,7 +1,7 @@
LineBreakpoint created at fileWithInternal.kt:5
LineBreakpoint created at fileWithInternal.kt:6
Run Java
Connected to the target VM
fileWithInternal.kt:5
fileWithInternal.kt:6
Compile bytecode for 1
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: inlineFunInMultiFilePackage.kt
package inlineFunInMultiFilePackage
fun main(args: Array<String>) {
@@ -8,3 +9,9 @@ fun main(args: Array<String>) {
// EXPRESSION: multiFilePackage.foo { 1 }
// RESULT: 1: I
// FILE: multiFilePackage.kt
@file:JvmMultifileClass
@file:JvmName("NewName")
package multiFilePackage
inline fun foo(f: () -> Int) = f()
@@ -1,7 +1,7 @@
LineBreakpoint created at inlineFunInMultiFilePackage.kt:5
LineBreakpoint created at inlineFunInMultiFilePackage.kt:6
Run Java
Connected to the target VM
inlineFunInMultiFilePackage.kt:5
inlineFunInMultiFilePackage.kt:6
Compile bytecode for multiFilePackage.foo { 1 }
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: inlineFunction.kt
package inlineFunction
import inlineFunctionOtherPackage.*
@@ -13,4 +14,14 @@ inline fun foo() = 1
// RESULT: 1: I
// EXPRESSION: foo()
// RESULT: 1: I
// RESULT: 1: I
// FILE: lib.kt
package inlineFunctionOtherPackage
inline fun myFun(f: () -> Int): Int = f()
val String.prop: String
get() {
return "a"
}
@@ -1,7 +1,7 @@
LineBreakpoint created at inlineFunction.kt:7
LineBreakpoint created at inlineFunction.kt:8
Run Java
Connected to the target VM
inlineFunction.kt:7
inlineFunction.kt:8
Compile bytecode for myFun { 1 }
Compile bytecode for foo()
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: test.kt
package inlineFunctionBreakpointAnotherFile
fun main(args: Array<String>) {
@@ -10,4 +11,11 @@ fun main(args: Array<String>) {
}
}
// ADDITIONAL_BREAKPOINT: inlineFunctionWithBreakpoint.kt:inline fun myFun
// ADDITIONAL_BREAKPOINT: inlineFunctionWithBreakpoint.kt:inline fun myFun
// FILE: inlineFunctionWithBreakpoint.kt
package inlineFunctionWithBreakpoint
inline fun myFun(f: (Int) -> Unit) {
f(1)
}
@@ -1,7 +1,7 @@
LineBreakpoint created at inlineFunctionWithBreakpoint.kt:4
LineBreakpoint created at inlineFunctionWithBreakpoint.kt:5
Run Java
Connected to the target VM
inlineFunctionWithBreakpoint.kt:4
inlineFunctionWithBreakpoint.kt:5
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: jcBlock.kt
package jcBlock
fun main(args: Array<String>) {
@@ -16,4 +17,20 @@ fun main(args: Array<String>) {
// RESULT: 1: I
// EXPRESSION: elseVal
// RESULT: Unresolved reference: elseVal
// RESULT: Unresolved reference: elseVal
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public void block() {
int bodyVal = 1;
if (true) {
int thenVal = 1;
int breakpoint = 1;
}
else {
int elseVal = 1;
}
}
}
@@ -1,10 +1,10 @@
LineBreakpoint created at jcBlock.kt:6
LineBreakpoint created at jcBlock.kt:7
Run Java
Connected to the target VM
jcBlock.kt:6
JavaClass.java:16
JavaClass.java:18
JavaClass.java:19
jcBlock.kt:7
JavaClass.java:6
JavaClass.java:8
JavaClass.java:9
Compile bytecode for bodyVal
Compile bytecode for thenVal
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: jcImports.kt
package jcImports
fun main(args: Array<String>) {
@@ -10,4 +11,23 @@ fun main(args: Array<String>) {
// STEP_OVER: 1
// EXPRESSION: list.filter { it == 1 }.size
// RESULT: 1: I
// RESULT: 1: I
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
import java.util.ArrayList;
public class JavaClass {
public void imports() {
ArrayList<Integer> list = createList();
int breakpoint = 1;
}
private ArrayList<Integer> createList() {
ArrayList<Integer> list = new ArrayList<Integer>();
list.add(1);
list.add(2);
return list;
}
}
@@ -1,9 +1,9 @@
LineBreakpoint created at jcImports.kt:6
LineBreakpoint created at jcImports.kt:7
Run Java
Connected to the target VM
jcImports.kt:6
JavaClass.java:27
JavaClass.java:28
jcImports.kt:7
JavaClass.java:8
JavaClass.java:9
Compile bytecode for list.filter { it == 1 }.size
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: jcLocalVariable.kt
package jcLocalVariable
fun main(args: Array<String>) {
@@ -10,4 +11,14 @@ fun main(args: Array<String>) {
// STEP_OVER: 1
// EXPRESSION: i
// RESULT: 1: I
// RESULT: 1: I
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public void localVariable() {
int i = 1;
int breakpoint = 1;
}
}
@@ -1,9 +1,9 @@
LineBreakpoint created at jcLocalVariable.kt:6
LineBreakpoint created at jcLocalVariable.kt:7
Run Java
Connected to the target VM
jcLocalVariable.kt:6
JavaClass.java:11
JavaClass.java:12
jcLocalVariable.kt:7
JavaClass.java:6
JavaClass.java:7
Compile bytecode for i
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: test.kt
package jcMarkedObject
fun main(args: Array<String>) {
@@ -15,4 +16,14 @@ fun main(args: Array<String>) {
// EXPRESSION: i_DebugLabel
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
// DEBUG_LABEL: i = i
// DEBUG_LABEL: i = i
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public void markObject() {
Integer i = 1;
int breakpoint = 1;
}
}
@@ -1,9 +1,9 @@
LineBreakpoint created at jcMarkedObject.kt:6
LineBreakpoint created at test.kt:7
Run Java
Connected to the target VM
jcMarkedObject.kt:6
JavaClass.java:39
JavaClass.java:40
test.kt:7
JavaClass.java:6
JavaClass.java:7
Compile bytecode for i
Compile bytecode for i_DebugLabel
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: test.kt
package jcProperty
fun main(args: Array<String>) {
@@ -15,4 +16,16 @@ fun main(args: Array<String>) {
// RESULT: 1: I
// EXPRESSION: javaPrivateProperty
// RESULT: 1: I
// RESULT: 1: I
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public int javaProperty = 1;
private int javaPrivateProperty = 1;
public void property() {
int breakpoint = 1;
}
}
@@ -1,8 +1,8 @@
LineBreakpoint created at jcProperty.kt:6
LineBreakpoint created at test.kt:7
Run Java
Connected to the target VM
jcProperty.kt:6
JavaClass.java:47
test.kt:7
JavaClass.java:9
Compile bytecode for this.javaProperty
Compile bytecode for javaProperty
Compile bytecode for javaPrivateProperty
@@ -1,3 +1,4 @@
// FILE: jcSimple.kt
package jcSimple
fun main(args: Array<String>) {
@@ -9,4 +10,13 @@ fun main(args: Array<String>) {
// STEP_INTO: 1
// EXPRESSION: 1 + 1
// RESULT: 2: I
// RESULT: 2: I
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public void simple() {
int breakpoint = 1;
}
}
@@ -1,8 +1,8 @@
LineBreakpoint created at jcSimple.kt:6
LineBreakpoint created at jcSimple.kt:7
Run Java
Connected to the target VM
jcSimple.kt:6
JavaClass.java:7
jcSimple.kt:7
JavaClass.java:6
Compile bytecode for 1 + 1
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: javaStaticMethods.kt
package javaStaticMethods
import forTests.javaContext.JavaClass.JavaStatic
@@ -9,3 +10,12 @@ fun main() {
// EXPRESSION: JavaStatic.state()
// RESULT: 1: I
// FILE: forTests/javaContext/JavaClass.java
package forTests.javaContext;
public class JavaClass {
public interface JavaStatic {
static int state() { return 1; }
}
}
@@ -1,7 +1,7 @@
LineBreakpoint created at javaStaticMethods.kt:7
LineBreakpoint created at javaStaticMethods.kt:8
Run Java
Connected to the target VM
javaStaticMethods.kt:7
javaStaticMethods.kt:8
Compile bytecode for JavaStatic.state()
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: privateClass.kt
package privateClass
fun main(args: Array<String>) {
@@ -32,3 +33,15 @@ class A {
// EXPRESSION: forTests.MyJavaClass.PrivateJavaClass().prop
// RESULT: 1: I
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
import java.util.List;
public class MyJavaClass {
private static class PrivateJavaClass {
public final int prop = 1;
}
}
@@ -1,7 +1,7 @@
LineBreakpoint created at privateClass.kt:5
LineBreakpoint created at privateClass.kt:6
Run Java
Connected to the target VM
privateClass.kt:5
privateClass.kt:6
Compile bytecode for A.PrivateClass()
Compile bytecode for A.PrivateClass().prop
Compile bytecode for A().PrivateInnerClass()
@@ -1,3 +1,4 @@
// FILE: rawTypeskt11831.kt
package rawTypeskt11831
fun main(args: Array<String>) {
@@ -8,4 +9,22 @@ fun main(args: Array<String>) {
}
// EXPRESSION: foo
// RESULT: 1: I
// RESULT: 1: I
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
import java.util.List;
public class MyJavaClass {
public static class RawA<T> {
public int foo(List<T> p) {
return 1;
}
}
public static class RawADerived extends RawA {
}
}
@@ -1,7 +1,7 @@
LineBreakpoint created at rawTypeskt11831.kt:7
LineBreakpoint created at rawTypeskt11831.kt:8
Run Java
Connected to the target VM
rawTypeskt11831.kt:7
rawTypeskt11831.kt:8
Compile bytecode for foo
Disconnected from the target VM
@@ -0,0 +1,37 @@
package forTests
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.EmptyCoroutineContext
import kotlin.coroutines.startCoroutine
import java.util.concurrent.CountDownLatch
import java.util.concurrent.TimeUnit
open class EmptyContinuation(override val context: CoroutineContext = EmptyCoroutineContext) : Continuation<Any?> {
companion object : EmptyContinuation()
override fun resumeWith(result: Result<Any?>) { result.getOrThrow() }
}
fun builder(c: suspend () -> Unit) {
c.startCoroutine(EmptyContinuation)
}
class WaitFinish(
private val timeout: Long = 5,
private val unit: TimeUnit = TimeUnit.SECONDS
) {
private val cdl = CountDownLatch(1)
fun finish() {
cdl.countDown()
}
fun waitEnd() {
if (!cdl.await(timeout, unit)) {
throw java.lang.IllegalStateException("Too long wait in debugger test!")
}
Thread.sleep(10)
}
}
@@ -3,4 +3,6 @@ package streams.sequence.sort
fun main(args: Array<String>) {
//Breakpoint!
arrayOf(Person("Bob", 42), Person("Alice", 27)).asSequence().sortedByDescending { it.age }.count()
}
}
data class Person(val name: String, val age: Int)
@@ -4,4 +4,6 @@ fun main(args: Array<String>) {
//Breakpoint!
arrayOf(Person("Bob", 42), Person("Alice", 27)).asSequence()
.sortedWith(compareBy { it.name }).count()
}
}
data class Person(val name: String, val age: Int)
@@ -1,3 +1,5 @@
// ATTACH_LIBRARY: coroutines
package coroutine
import forTests.builder
@@ -1,9 +1,9 @@
LineBreakpoint created at coroutine.kt:15
LineBreakpoint created at coroutine.kt:17
Run Java
Connected to the target VM
coroutine.kt:15
coroutine.kt:15
coroutine.kt:16
coroutine.kt:17
coroutine.kt:17
coroutine.kt:18
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,6 @@
// FILE: inlineInObjectSameFileDex.kt
// EMULATE_DEX: true
package inlineInObjectSameFileDex
fun main(args: Array<String>) {
@@ -1,9 +1,9 @@
LineBreakpoint created at inlineInObjectSameFileDex.kt:5
LineBreakpoint created at inlineInObjectSameFileDex.kt:11
LineBreakpoint created at inlineInObjectSameFileDex.kt:8
LineBreakpoint created at inlineInObjectSameFileDex.kt:14
Run Java
Connected to the target VM
inlineInObjectSameFileDex.kt:5
inlineInObjectSameFileDex.kt:11
inlineInObjectSameFileDex.kt:8
inlineInObjectSameFileDex.kt:14
Disconnected from the target VM
Process finished with exit code 0
@@ -1,6 +0,0 @@
package manyFilesWithInlineCalls1Dex.first
inline fun firstInline() {
// Breakpoint 1
1 + 1
}
@@ -1,5 +0,0 @@
package manyFilesWithInlineCalls1Dex.second
inline fun secondInline() {
1 + 1
}
@@ -1,3 +1,6 @@
// EMULATE_DEX: true
// FILE: manyFilesWithInlineCalls1Dex.kt
package manyFilesWithInlineCalls1Dex
import manyFilesWithInlineCalls1Dex.first.*
@@ -11,4 +14,19 @@ fun unused() {
secondInline()
}
// ADDITIONAL_BREAKPOINT: manyFilesWithInlineCalls1Dex.First.kt: Breakpoint 1
// ADDITIONAL_BREAKPOINT: manyFilesWithInlineCalls1Dex.First.kt: Breakpoint 1
// FILE: manyFilesWithInlineCalls1Dex.First.kt
package manyFilesWithInlineCalls1Dex.first
inline fun firstInline() {
// Breakpoint 1
1 + 1
}
// FILE: manyFilesWithInlineCalls1Dex.Second.kt
package manyFilesWithInlineCalls1Dex.second
inline fun secondInline() {
1 + 1
}
@@ -1,7 +1,7 @@
LineBreakpoint created at manyFilesWithInlineCalls1Dex.First.kt:5
LineBreakpoint created at manyFilesWithInlineCalls1Dex.First.kt:6
Run Java
Connected to the target VM
manyFilesWithInlineCalls1Dex.First.kt:5
manyFilesWithInlineCalls1Dex.First.kt:6
Disconnected from the target VM
Process finished with exit code 0
@@ -1,5 +0,0 @@
package manyFilesWithInlineCalls2Dex.first
inline fun firstInline() {
1 + 1
}
@@ -1,6 +0,0 @@
package manyFilesWithInlineCalls2Dex.second
inline fun secondInline() {
// Breakpoint 1
1 + 1
}
@@ -1,3 +1,6 @@
// EMULATE_DEX: true
// FILE: manyFilesWithInlineCalls2Dex.kt
package manyFilesWithInlineCalls2Dex
import manyFilesWithInlineCalls2Dex.first.*
@@ -11,4 +14,19 @@ fun unused() {
firstInline()
}
// ADDITIONAL_BREAKPOINT: manyFilesWithInlineCalls2Dex.Second.kt: Breakpoint 1
// ADDITIONAL_BREAKPOINT: manyFilesWithInlineCalls2Dex.Second.kt: Breakpoint 1
// FILE: manyFilesWithInlineCalls2Dex.First.kt
package manyFilesWithInlineCalls2Dex.first
inline fun firstInline() {
1 + 1
}
// FILE: manyFilesWithInlineCalls2Dex.Second.kt
package manyFilesWithInlineCalls2Dex.second
inline fun secondInline() {
// Breakpoint 1
1 + 1
}
@@ -1,7 +1,7 @@
LineBreakpoint created at manyFilesWithInlineCalls2Dex.Second.kt:5
LineBreakpoint created at manyFilesWithInlineCalls2Dex.Second.kt:6
Run Java
Connected to the target VM
manyFilesWithInlineCalls2Dex.Second.kt:5
manyFilesWithInlineCalls2Dex.Second.kt:6
Disconnected from the target VM
Process finished with exit code 0
@@ -1,8 +0,0 @@
package severalInlineCallsFromOtherFileDex
inline fun inlineFun() {
var i = 1
// Breakpoint 1
i++
i++
}
@@ -1,3 +1,6 @@
// FILE: severalInlineCallsFromOtherFileDex.kt
// EMULATE_DEX: true
package severalInlineCallsFromOtherFileDex
fun main(args: Array<String>) {
@@ -16,3 +19,13 @@ fun secondCall() {
// RESUME: 2
// ADDITIONAL_BREAKPOINT: severalInlineCallsFromOtherFileDex.Other.kt: Breakpoint 1
// FILE: severalInlineCallsFromOtherFileDex.Other.kt
package severalInlineCallsFromOtherFileDex
inline fun inlineFun() {
var i = 1
// Breakpoint 1
i++
i++
}
@@ -1,10 +1,10 @@
LineBreakpoint created at severalInlineCallsFromOtherFileDex.Other.kt:6
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:5
LineBreakpoint created at severalInlineCallsFromOtherFileDex.Other.kt:7
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:8
Run Java
Connected to the target VM
severalInlineCallsFromOtherFileDex.kt:5
severalInlineCallsFromOtherFileDex.Other.kt:6
severalInlineCallsFromOtherFileDex.Other.kt:6
severalInlineCallsFromOtherFileDex.kt:8
severalInlineCallsFromOtherFileDex.Other.kt:7
severalInlineCallsFromOtherFileDex.Other.kt:7
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,6 @@
// FILE: severalInlineCallsFromOtherFileDex.kt
// EMULATE_DEX: true
package severalInlineCallsFromOtherFileDex
fun main(args: Array<String>) {
@@ -1,6 +1,23 @@
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:8
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:26
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:32
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:37
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:44
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:49
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:56
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:63
LineBreakpoint created at severalInlineCallsFromOtherFileDex.kt:69
Run Java
Connected to the target VM
severalInlineCallsFromOtherFileDex.kt:8
severalInlineCallsFromOtherFileDex.kt:26
severalInlineCallsFromOtherFileDex.kt:32
severalInlineCallsFromOtherFileDex.kt:44
severalInlineCallsFromOtherFileDex.kt:69
severalInlineCallsFromOtherFileDex.kt:37
severalInlineCallsFromOtherFileDex.kt:49
severalInlineCallsFromOtherFileDex.kt:56
severalInlineCallsFromOtherFileDex.kt:63
Disconnected from the target VM
Process finished with exit code 1
Error: Could not find or load main class severalInlineFunctionsInOneFileDex.SeveralInlineFunctionsInOneFileDexKt
Process finished with exit code 0
@@ -1,6 +1,7 @@
LineBreakpoint created at simpleConditionalBreakpoint.kt:5 condition = 1 == 1
Run Java
Connected to the target VM
Compile bytecode for 1 == 1
simpleConditionalBreakpoint.kt:5
Disconnected from the target VM
@@ -1,3 +1,4 @@
// FILE: smartStepIntoInterfaceImpl.kt
package smartStepIntoInterfaceImpl
import forTests.MyJavaClass
@@ -153,3 +154,16 @@ fun testStepInto() {
//Breakpoint!
Obj2.staticCallInOverride("a")
}
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
import java.util.List;
public class MyJavaClass {
@NotNull
public static int staticFun(Object s) {
return 1;
}
}
@@ -1,40 +1,40 @@
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:90
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:95
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:100
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:105
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:110
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:120
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:125
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:130
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:138
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:143
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:148
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:154
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:91
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:96
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:101
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:106
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:111
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:121
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:126
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:131
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:139
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:144
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:149
LineBreakpoint created at smartStepIntoInterfaceImpl.kt:155
Run Java
Connected to the target VM
smartStepIntoInterfaceImpl.kt:90
smartStepIntoInterfaceImpl.kt:95
smartStepIntoInterfaceImpl.kt:8
smartStepIntoInterfaceImpl.kt:100
smartStepIntoInterfaceImpl.kt:13
smartStepIntoInterfaceImpl.kt:105
smartStepIntoInterfaceImpl.kt:13
smartStepIntoInterfaceImpl.kt:110
smartStepIntoInterfaceImpl.kt:18
smartStepIntoInterfaceImpl.kt:120
smartStepIntoInterfaceImpl.kt:22
smartStepIntoInterfaceImpl.kt:125
smartStepIntoInterfaceImpl.kt:36
smartStepIntoInterfaceImpl.kt:130
smartStepIntoInterfaceImpl.kt:41
smartStepIntoInterfaceImpl.kt:138
MyJavaClass.java:17
smartStepIntoInterfaceImpl.kt:143
smartStepIntoInterfaceImpl.kt:59
smartStepIntoInterfaceImpl.kt:148
smartStepIntoInterfaceImpl.kt:64
smartStepIntoInterfaceImpl.kt:154
smartStepIntoInterfaceImpl.kt:70
smartStepIntoInterfaceImpl.kt:91
smartStepIntoInterfaceImpl.kt:96
smartStepIntoInterfaceImpl.kt:9
smartStepIntoInterfaceImpl.kt:101
smartStepIntoInterfaceImpl.kt:14
smartStepIntoInterfaceImpl.kt:106
smartStepIntoInterfaceImpl.kt:14
smartStepIntoInterfaceImpl.kt:111
smartStepIntoInterfaceImpl.kt:19
smartStepIntoInterfaceImpl.kt:121
smartStepIntoInterfaceImpl.kt:23
smartStepIntoInterfaceImpl.kt:126
smartStepIntoInterfaceImpl.kt:37
smartStepIntoInterfaceImpl.kt:131
smartStepIntoInterfaceImpl.kt:42
smartStepIntoInterfaceImpl.kt:139
MyJavaClass.java:10
smartStepIntoInterfaceImpl.kt:144
smartStepIntoInterfaceImpl.kt:60
smartStepIntoInterfaceImpl.kt:149
smartStepIntoInterfaceImpl.kt:65
smartStepIntoInterfaceImpl.kt:155
smartStepIntoInterfaceImpl.kt:71
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: stepIntoStdlibInlineFun2step.kt
package stepIntoStdlibInlineFun2step
fun main(args: Array<String>) {
@@ -5,4 +6,15 @@ fun main(args: Array<String>) {
}
// ADDITIONAL_BREAKPOINT: functionInLibrary.kt:public inline fun simpleFun()
// STEP_INTO: 5
// STEP_INTO: 5
// FILE: customLib/functionInLibrary/functionInLibrary.kt
package customLib.functionInLibrary
public inline fun simpleFun() {
nextFun()
}
public inline fun nextFun() {
val a = 1
}
@@ -1,11 +1,11 @@
LineBreakpoint created at functionInLibrary.kt:4
LineBreakpoint created at functionInLibrary.kt:5
Run Java
Connected to the target VM
functionInLibrary.kt:4
functionInLibrary.kt:8
functionInLibrary.kt:9
functionInLibrary.kt:5
stepIntoStdlibInlineFun2step.kt:5
functionInLibrary.kt:9
functionInLibrary.kt:10
functionInLibrary.kt:6
stepIntoStdlibInlineFun2step.kt:6
Disconnected from the target VM
Process finished with exit code 0
@@ -2,8 +2,8 @@ LineBreakpoint created at stepOutInlineFunctionStdlib.kt:6
Run Java
Connected to the target VM
stepOutInlineFunctionStdlib.kt:6
stepOutInlineFunctionStdlib.kt:1
Thread.!EXT!
_Collections.!EXT!
stepOutInlineFunctionStdlib.kt:9
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: checkNotNull.kt
package checkNotNull
import forTests.MyJavaClass
@@ -10,3 +11,17 @@ fun main(args: Array<String>) {
}
// STEP_INTO: 3
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
public class MyJavaClass {
@NotNull
public String testNotNullFun() {
return "a";
}
public MyJavaClass() {}
}
@@ -1,10 +1,10 @@
LineBreakpoint created at checkNotNull.kt:8
LineBreakpoint created at checkNotNull.kt:9
Run Java
Connected to the target VM
checkNotNull.kt:8
MyJavaClass.java:13
checkNotNull.kt:8
checkNotNull.kt:9
MyJavaClass.java:9
checkNotNull.kt:9
checkNotNull.kt:10
Disconnected from the target VM
Process finished with exit code 0
@@ -4,7 +4,7 @@ fun main(args: Array<String>) {
val loader = A::class.java.getClassLoader()!!
try {
//Breakpoint!
val aaa = loader.loadClass("skipClassloader.A")
val aaa = loader.loadClass("doNotSkipClassloader.A")
}
catch (e: ClassNotFoundException) {
e.printStackTrace()
@@ -1,3 +1,4 @@
// FILE: stepIntoMultiFileFacade.kt
package stepIntoMultiFileFacade
fun main(args: Array<String>) {
@@ -6,4 +7,22 @@ fun main(args: Array<String>) {
}
// STEP_INTO: 2
// TRACING_FILTERS_ENABLED: false
// TRACING_FILTERS_ENABLED: false
// FILE: oneFunSameClassName/1/a1.kt
@file:JvmName("SameNameOneFunSameFileName")
@file:JvmMultifileClass
package customLib.oneFunSameClassName
public fun oneFunSameFileNameFun(): Int {
return 1
}
// FILE: oneFunSameClassName/2/a2.kt
@file:JvmName("SameNameOneFunSameFileName")
@file:JvmMultifileClass
package customLib.oneFunSameClassName
public fun oneFunSameFileNameFun2(): Int {
return 1
}
@@ -1,9 +1,9 @@
LineBreakpoint created at stepIntoMultiFileFacade.kt:5
LineBreakpoint created at stepIntoMultiFileFacade.kt:6
Run Java
Connected to the target VM
stepIntoMultiFileFacade.kt:5
a1.kt:6
stepIntoMultiFileFacade.kt:5
stepIntoMultiFileFacade.kt:6
a1.kt:7
stepIntoMultiFileFacade.kt:6
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: stepIntoSpecificKotlinClasses.kt
package stepIntoSpecificKotlinClasses
import forTests.MyJavaClass
@@ -12,3 +13,15 @@ fun main(args: Array<String>) {
// STEP_INTO: 5
// DISABLE_KOTLIN_INTERNAL_CLASSES: false
// TRACING_FILTERS_ENABLED: false
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
public class MyJavaClass {
@NotNull
public String testNotNullFun() {
return "a";
}
}
@@ -1,12 +1,12 @@
LineBreakpoint created at stepIntoSpecificKotlinClasses.kt:8
LineBreakpoint created at stepIntoSpecificKotlinClasses.kt:9
Run Java
Connected to the target VM
stepIntoSpecificKotlinClasses.kt:8
MyJavaClass.java:13
stepIntoSpecificKotlinClasses.kt:8
stepIntoSpecificKotlinClasses.kt:9
MyJavaClass.java:9
stepIntoSpecificKotlinClasses.kt:9
Intrinsics.!EXT!
Intrinsics.!EXT!
stepIntoSpecificKotlinClasses.kt:8
stepIntoSpecificKotlinClasses.kt:9
Disconnected from the target VM
Process finished with exit code 0
@@ -2,7 +2,7 @@ LineBreakpoint created at stepIntoStdlib.kt:6
Run Java
Connected to the target VM
stepIntoStdlib.kt:6
ArraysKt.!EXT!
_Arrays.!EXT!
Disconnected from the target VM
Process finished with exit code 0
@@ -2,8 +2,8 @@ LineBreakpoint created at stepIntoStdlibFacadeClass.kt:6
Run Java
Connected to the target VM
stepIntoStdlibFacadeClass.kt:6
ArraysKt.!EXT!
Iterables.!EXT!
_Arrays.!EXT!
Intrinsics.!EXT!
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: defaultAccessors.kt
package defaultAccessors
fun main(args: Array<String>) {
@@ -25,4 +26,15 @@ fun testPublicPropertyInLibrary() {
// STEP_INTO: 21
// SKIP_SYNTHETIC_METHODS: true
// SKIP_CONSTRUCTORS: true
// SKIP_CONSTRUCTORS: true
// FILE: customLib/simpleLibFile.kt
package customLib.simpleLibFile
public fun foo() {
1 + 1
}
class B {
public var prop: Int = 1
}
@@ -1,22 +1,22 @@
LineBreakpoint created at defaultAccessors.kt:5
LineBreakpoint created at defaultAccessors.kt:6
Run Java
Connected to the target VM
defaultAccessors.kt:5
defaultAccessors.kt:11
defaultAccessors.kt:17
defaultAccessors.kt:11
defaultAccessors.kt:12
defaultAccessors.kt:17
defaultAccessors.kt:13
defaultAccessors.kt:6
defaultAccessors.kt:21
defaultAccessors.kt:22
simpleLibFile.kt:8
defaultAccessors.kt:12
defaultAccessors.kt:18
defaultAccessors.kt:12
defaultAccessors.kt:13
defaultAccessors.kt:18
defaultAccessors.kt:14
defaultAccessors.kt:7
defaultAccessors.kt:22
defaultAccessors.kt:23
simpleLibFile.kt:8
simpleLibFile.kt:9
defaultAccessors.kt:23
defaultAccessors.kt:24
defaultAccessors.kt:7
simpleLibFile.kt:9
defaultAccessors.kt:25
defaultAccessors.kt:8
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,6 @@
// EMULATE_DEX: true
// FILE: trueseveralInlineFunctionsInOneFileDex.kt
package inlineDex
fun main(args: Array<String>) {
@@ -1,8 +1,8 @@
LineBreakpoint created at inlineDex.kt:5
LineBreakpoint created at trueseveralInlineFunctionsInOneFileDex.kt:8
Run Java
Connected to the target VM
inlineDex.kt:5
inlineDex.kt:9
trueseveralInlineFunctionsInOneFileDex.kt:8
trueseveralInlineFunctionsInOneFileDex.kt:12
Disconnected from the target VM
Process finished with exit code 0
@@ -27,5 +27,4 @@ inline fun forEach(s: () -> Unit) {
}
}
// STEP_INTO: 9
// TRACING_FILTERS_ENABLED: false
// STEP_INTO: 10
@@ -10,7 +10,7 @@ inlineOnly.kt:13
inlineOnly.kt:14
inlineOnly.kt:7
inlineOnly.kt:9
PrintStream.!EXT!
inlineOnly.kt:10
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: samAdapter.kt
package samAdapter
fun main(args: Array<String>) {
@@ -10,4 +11,22 @@ fun runReadAction(action: () -> Int): Int {
return forTests.MyJavaClass.runReadAction<Int>(action)
}
// STEP_INTO: 8
// STEP_INTO: 8
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
public class MyJavaClass {
public static <T> T runReadAction(@NotNull Computable<T> computation) {
return computation.compute();
}
}
// FILE: forTests/Computable.java
package forTests;
public interface Computable <T> {
T compute();
}
@@ -1,15 +1,15 @@
LineBreakpoint created at samAdapter.kt:5
LineBreakpoint created at samAdapter.kt:6
Run Java
Connected to the target VM
samAdapter.kt:5
samAdapter.kt:6
samAdapter.kt:10
MyJavaClass.java:21
samAdapter.kt:6
MyJavaClass.java:21
samAdapter.kt:10
samAdapter.kt:6
samAdapter.kt:7
samAdapter.kt:11
MyJavaClass.java:8
samAdapter.kt:7
MyJavaClass.java:8
samAdapter.kt:11
samAdapter.kt:7
samAdapter.kt:8
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: sameFileNames.kt
package sameFileNames
fun main() {
@@ -5,4 +6,11 @@ fun main() {
val result = simple.foo()
}
// STEP_INTO: 1
// STEP_INTO: 1
// FILE: simple.kt
package simple
// test more than one file for package in JetPositionManager:prepareTypeMapper. the second file in this package is singleBreakpoint/simple.kt
fun foo() {
}
@@ -1,8 +1,8 @@
LineBreakpoint created at sameFileNames.kt:5
LineBreakpoint created at sameFileNames.kt:6
Run Java
Connected to the target VM
sameFileNames.kt:5
simpleKt.kt:5
sameFileNames.kt:6
simple.kt:6
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,5 @@
// ATTACH_LIBRARY: coroutines
package siSuspendFun
import forTests.builder
@@ -1,12 +1,12 @@
LineBreakpoint created at siSuspendFun.kt:29
LineBreakpoint created at siSuspendFun.kt:31
Run Java
Connected to the target VM
siSuspendFun.kt:29
siSuspendFun.kt:22
siSuspendFun.kt:18
siSuspendFun.kt:14
siSuspendFun.kt:10
siSuspendFun.kt:6
siSuspendFun.kt:31
siSuspendFun.kt:24
siSuspendFun.kt:20
siSuspendFun.kt:16
siSuspendFun.kt:12
siSuspendFun.kt:8
Disconnected from the target VM
Process finished with exit code 0
@@ -2,7 +2,7 @@ LineBreakpoint created at stepIntoStdLibInlineFun.kt:6
Run Java
Connected to the target VM
stepIntoStdLibInlineFun.kt:6
stepIntoStdLibInlineFun.kt:1
_Collections.!EXT!
resuming stepIntoStdLibInlineFun.kt:6
Disconnected from the target VM
@@ -1,3 +1,5 @@
// ATTACH_LIBRARY: coroutines
package stepIntoSuspendFunctionSimple
import forTests.builder
@@ -1,8 +1,8 @@
LineBreakpoint created at stepIntoSuspendFunctionSimple.kt:18
LineBreakpoint created at stepIntoSuspendFunctionSimple.kt:20
Run Java
Connected to the target VM
stepIntoSuspendFunctionSimple.kt:18
stepIntoSuspendFunctionSimple.kt:10
stepIntoSuspendFunctionSimple.kt:20
stepIntoSuspendFunctionSimple.kt:12
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: javaFun.kt
package javaFun
import forTests.MyJavaClass
@@ -7,3 +8,17 @@ fun main(args: Array<String>) {
//Breakpoint!
klass.testFun()
}
// FILE: forTests/MyJavaClass.java
package forTests;
import org.jetbrains.annotations.NotNull;
import java.util.List;
public class MyJavaClass {
public void testFun() {
int i = 1;
}
public MyJavaClass() {}
}
@@ -1,8 +1,8 @@
LineBreakpoint created at javaFun.kt:8
LineBreakpoint created at javaFun.kt:9
Run Java
Connected to the target VM
javaFun.kt:8
MyJavaClass.java:8
javaFun.kt:9
MyJavaClass.java:9
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: javaSamConstructor.kt
package javaSamConstructor
import forTests.MyJavaClass
@@ -5,4 +6,12 @@ import forTests.MyJavaClass
fun main(args: Array<String>) {
//Breakpoint!
MyJavaClass { /* do nothing*/ }
}
// FILE: forTests/MyJavaClass.java
package forTests;
public class MyJavaClass {
public MyJavaClass() {}
public MyJavaClass(Runnable runnable) {}
}
@@ -1,8 +1,8 @@
LineBreakpoint created at javaSamConstructor.kt:7
LineBreakpoint created at javaSamConstructor.kt:8
Run Java
Connected to the target VM
javaSamConstructor.kt:7
MyJavaClass.java:61
javaSamConstructor.kt:8
MyJavaClass.java:6
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: javaSamFunction.kt
package javaSamFunction
import forTests.MyJavaClass
@@ -6,4 +7,15 @@ fun main(args: Array<String>) {
val klass = MyJavaClass()
//Breakpoint!
klass.other { /* do nothing*/ }
}
// FILE: forTests/MyJavaClass.java
package forTests;
public class MyJavaClass {
public void other(Runnable runnable) {
runnable.run();
}
public MyJavaClass() {}
}
@@ -1,9 +1,9 @@
LineBreakpoint created at javaSamFunction.kt:8
LineBreakpoint created at javaSamFunction.kt:9
Run Java
Connected to the target VM
javaSamFunction.kt:8
MyJavaClass.java:55
resuming javaSamFunction.kt:8
javaSamFunction.kt:9
MyJavaClass.java:6
resuming javaSamFunction.kt:9
Disconnected from the target VM
Process finished with exit code 0
@@ -1,3 +1,4 @@
// FILE: kotlinSamFunction.kt
package kotlinSamFunction
import forTests.MyJavaClass
@@ -12,4 +13,13 @@ fun main(args: Array<String>) {
val klass = KotlinSubclass()
//Breakpoint!
klass.other { /* do nothing*/ }
}
}
// FILE: forTests/MyJavaClass.java
package forTests;
public class MyJavaClass {
public void other(Runnable runnable) {
runnable.run();
}
}

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