diff options
Diffstat (limited to 'tools/aapt2/java/ProguardRules_test.cpp')
-rw-r--r-- | tools/aapt2/java/ProguardRules_test.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/aapt2/java/ProguardRules_test.cpp b/tools/aapt2/java/ProguardRules_test.cpp index b5e27e0cb952..6e0df50bd9c4 100644 --- a/tools/aapt2/java/ProguardRules_test.cpp +++ b/tools/aapt2/java/ProguardRules_test.cpp @@ -37,7 +37,10 @@ std::string GetKeepSetString(const proguard::KeepSet& set) { TEST(ProguardRulesTest, ManifestRuleDefaultConstructorOnly) { std::unique_ptr<xml::XmlResource> manifest = test::BuildXmlDom(R"( <manifest xmlns:android="http://schemas.android.com/apk/res/android"> - <application android:backupAgent="com.foo.BarBackupAgent"> + <application + android:backupAgent="com.foo.BarBackupAgent" + android:name="com.foo.BarApplication" + > <activity android:name="com.foo.BarActivity"/> <service android:name="com.foo.BarService"/> <receiver android:name="com.foo.BarReceiver"/> @@ -52,6 +55,7 @@ TEST(ProguardRulesTest, ManifestRuleDefaultConstructorOnly) { std::string actual = GetKeepSetString(set); EXPECT_THAT(actual, HasSubstr("-keep class com.foo.BarBackupAgent { <init>(); }")); + EXPECT_THAT(actual, HasSubstr("-keep class com.foo.BarApplication { <init>(); }")); EXPECT_THAT(actual, HasSubstr("-keep class com.foo.BarActivity { <init>(); }")); EXPECT_THAT(actual, HasSubstr("-keep class com.foo.BarService { <init>(); }")); EXPECT_THAT(actual, HasSubstr("-keep class com.foo.BarReceiver { <init>(); }")); |