use of jadx.core.dex.nodes.ClassNode in project jadx by skylot.
the class TestLoopDetection3 method test.
@Test
public void test() {
ClassNode cls = getClassNode(TestCls.class);
String code = cls.getCode().toString();
assertThat(code, containsString("while"));
// TODO
// assertThat(code, containsString("while (--pos >= 0) {"));
}
use of jadx.core.dex.nodes.ClassNode in project jadx by skylot.
the class TestLoopDetection4 method test.
@Test
public void test() {
ClassNode cls = getClassNode(TestCls.class);
String code = cls.getCode().toString();
assertThat(code, containsOne("while (this.iterator.hasNext()) {"));
assertThat(code, containsOne("if (filtered != null) {"));
assertThat(code, containsOne("return filtered;"));
assertThat(code, containsOne("return null;"));
}
use of jadx.core.dex.nodes.ClassNode in project jadx by skylot.
the class TestNestedLoops2 method test.
@Test
public void test() {
ClassNode cls = getClassNode(TestCls.class);
String code = cls.getCode().toString();
assertThat(code, containsOne("for (int i = 0; i < list.size(); i++) {"));
assertThat(code, containsOne("while (j < ((String) list.get(i)).length()) {"));
}
use of jadx.core.dex.nodes.ClassNode in project jadx by skylot.
the class TestTryCatchInLoop method test.
@Test
public void test() {
ClassNode cls = getClassNode(TestCls.class);
String code = cls.getCode().toString();
assertThat(code, containsOne("} catch (Exception e) {"));
assertThat(code, containsOne("break;"));
}
use of jadx.core.dex.nodes.ClassNode in project jadx by skylot.
the class TestSameMethodsNames method test.
@Test
public void test() {
ClassNode cls = getClassNode(TestCls.class);
String code = cls.getCode().toString();
assertThat(code, containsOne("new Bug().Bug();"));
}
Aggregations