mirror of
https://github.com/skylot/jadx.git
synced 2024-11-26 22:20:50 +00:00
fix test
This commit is contained in:
parent
02bc27e887
commit
5640f3b931
@ -1,9 +1,14 @@
|
||||
package jadx.tests.integration.deobf.a;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import jadx.api.deobf.IDeobfCondition;
|
||||
import jadx.api.deobf.impl.CombineDeobfConditions;
|
||||
import jadx.core.deobf.conditions.AvoidClsAndPkgNamesCollision;
|
||||
import jadx.core.deobf.conditions.JadxRenameConditions;
|
||||
import jadx.tests.api.IntegrationTest;
|
||||
|
||||
import static jadx.tests.api.utils.assertj.JadxAssertions.assertThat;
|
||||
@ -34,6 +39,11 @@ public class TestNegativeRenameCondition extends IntegrationTest {
|
||||
// disable all renaming options
|
||||
args.setRenameFlags(Collections.emptySet());
|
||||
|
||||
// disable rename by collision between class and package names
|
||||
List<IDeobfCondition> list = JadxRenameConditions.buildDefaultDeobfConditions();
|
||||
list.removeIf(c -> c.getClass().equals(AvoidClsAndPkgNamesCollision.class));
|
||||
args.setRenameCondition(CombineDeobfConditions.combine(list));
|
||||
|
||||
assertThat(getClassNode(TestCls.class))
|
||||
.code()
|
||||
.doesNotContain("renamed from")
|
||||
|
Loading…
Reference in New Issue
Block a user