Skip to content

Corrected issue-message. #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 1, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public class MainActivityDetector extends ResourceXmlDetector implements Detecto
Severity.ERROR,
new Implementation(
MainActivityDetector.class,
EnumSet.of(Scope.MANIFEST)));
Scope.MANIFEST_SCOPE));

/**
* This will be <code>true</code> if the current file we're checking has at least one activity.
Expand Down Expand Up @@ -104,7 +104,7 @@ public void afterCheckProject(@NonNull Context context) {
&& mManifestLocation != null) {
if (!mHasActivity) {
context.report(ISSUE, mManifestLocation,
"Expecting " + ANDROID_MANIFEST_XML + " to have an <" + TAG_APPLICATION +
"Expecting " + ANDROID_MANIFEST_XML + " to have an <" + TAG_ACTIVITY +
"> tag.");
} else if (!mHasLauncherActivity) {
// Report the issue if the manifest file has no activity with a launcher intent.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public void testMissingMainActivity() throws Exception {
public void testMissingApplication() throws Exception {
mEnabled = Collections.singleton(MainActivityDetector.ISSUE);
String expected = "AndroidManifest.xml: Error: Expecting AndroidManifest.xml to have an " +
"<application> tag. [MainActivityDetector]\n" +
"<activity> tag. [MainActivityDetector]\n" +
"1 errors, 0 warnings\n";
String result = lintProject(xml(FN_ANDROID_MANIFEST_XML, "" +
"<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" +
Expand Down