Wed, 31 Dec 2014 07:16:47 +0100
Revert simplistic fix pending revisit of Mozilla integration attempt.
michael@0 | 1 | # This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 2 | # License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 3 | # file, You can obtain one at http://mozilla.org/MPL/2.0/. |
michael@0 | 4 | |
michael@0 | 5 | mobile-tests := mobile/android/base/tests |
michael@0 | 6 | TESTPATH := $(topsrcdir)/$(mobile-tests) |
michael@0 | 7 | dir-tests := $(DEPTH)/$(mobile-tests) |
michael@0 | 8 | |
michael@0 | 9 | ANDROID_APK_NAME := robocop-debug |
michael@0 | 10 | |
michael@0 | 11 | ANDROID_EXTRA_JARS += \ |
michael@0 | 12 | $(srcdir)/robotium-solo-4.3.1.jar \ |
michael@0 | 13 | $(NULL) |
michael@0 | 14 | |
michael@0 | 15 | ANDROID_ASSETS_DIR := $(TESTPATH)/assets |
michael@0 | 16 | |
michael@0 | 17 | _JAVA_HARNESS := \ |
michael@0 | 18 | Actions.java \ |
michael@0 | 19 | Assert.java \ |
michael@0 | 20 | Driver.java \ |
michael@0 | 21 | Element.java \ |
michael@0 | 22 | FennecInstrumentationTestRunner.java \ |
michael@0 | 23 | FennecNativeActions.java \ |
michael@0 | 24 | FennecMochitestAssert.java \ |
michael@0 | 25 | FennecTalosAssert.java \ |
michael@0 | 26 | FennecNativeDriver.java \ |
michael@0 | 27 | FennecNativeElement.java \ |
michael@0 | 28 | RoboCopException.java \ |
michael@0 | 29 | RobocopShare1.java \ |
michael@0 | 30 | RobocopShare2.java \ |
michael@0 | 31 | RobocopUtils.java \ |
michael@0 | 32 | PaintedSurface.java \ |
michael@0 | 33 | $(NULL) |
michael@0 | 34 | |
michael@0 | 35 | java-harness := $(addprefix $(srcdir)/,$(_JAVA_HARNESS)) |
michael@0 | 36 | java-tests := \ |
michael@0 | 37 | $(wildcard $(TESTPATH)/*.java) \ |
michael@0 | 38 | $(wildcard $(TESTPATH)/components/*.java) \ |
michael@0 | 39 | $(wildcard $(TESTPATH)/helpers/*.java) |
michael@0 | 40 | |
michael@0 | 41 | # pre-process TestConstants.java.in |
michael@0 | 42 | PP_TARGETS += testconstants |
michael@0 | 43 | testconstants-dep := $(dir-tests)/TestConstants.java |
michael@0 | 44 | testconstants := $(TESTPATH)/TestConstants.java.in |
michael@0 | 45 | testconstants_PATH := $(dir-tests) |
michael@0 | 46 | |
michael@0 | 47 | PP_TARGETS += manifest |
michael@0 | 48 | manifest := $(srcdir)/AndroidManifest.xml.in |
michael@0 | 49 | manifest_TARGET := AndroidManifest.xml |
michael@0 | 50 | ANDROID_MANIFEST_FILE := $(CURDIR)/AndroidManifest.xml |
michael@0 | 51 | |
michael@0 | 52 | # Install robocop configs and helper |
michael@0 | 53 | INSTALL_TARGETS += robocop |
michael@0 | 54 | robocop_TARGET := libs |
michael@0 | 55 | robocop_DEST := $(CURDIR) |
michael@0 | 56 | robocop_FILES := \ |
michael@0 | 57 | $(TESTPATH)/robocop.ini \ |
michael@0 | 58 | $(TESTPATH)/robocop_autophone.ini \ |
michael@0 | 59 | $(NULL) |
michael@0 | 60 | robocop-deps := $(notdir $(robocop_FILES)) |
michael@0 | 61 | |
michael@0 | 62 | ROBOCOP_FILES := \ |
michael@0 | 63 | $(wildcard $(TESTPATH)/*.html) \ |
michael@0 | 64 | $(wildcard $(TESTPATH)/*.jpg) \ |
michael@0 | 65 | $(wildcard $(TESTPATH)/*.sjs) \ |
michael@0 | 66 | $(wildcard $(TESTPATH)/test*.js) \ |
michael@0 | 67 | $(wildcard $(TESTPATH)/robocop*.js) \ |
michael@0 | 68 | $(wildcard $(TESTPATH)/*.xml) \ |
michael@0 | 69 | $(wildcard $(TESTPATH)/*.swf) \ |
michael@0 | 70 | $(NULL) |
michael@0 | 71 | |
michael@0 | 72 | ROBOCOP_DEST = $(DEPTH)/_tests/testing/mochitest/tests/robocop/ |
michael@0 | 73 | INSTALL_TARGETS += ROBOCOP |
michael@0 | 74 | |
michael@0 | 75 | GARBAGE += \ |
michael@0 | 76 | AndroidManifest.xml \ |
michael@0 | 77 | $(robocop-deps) \ |
michael@0 | 78 | $(testconstants-dep) \ |
michael@0 | 79 | $(NULL) |
michael@0 | 80 | |
michael@0 | 81 | JAVAFILES += \ |
michael@0 | 82 | $(java-harness) \ |
michael@0 | 83 | $(java-tests) \ |
michael@0 | 84 | $(robocop-deps) \ |
michael@0 | 85 | $(testconstants-dep) \ |
michael@0 | 86 | $(NULL) |
michael@0 | 87 | |
michael@0 | 88 | include $(topsrcdir)/config/rules.mk |
michael@0 | 89 | |
michael@0 | 90 | tools:: $(ANDROID_APK_NAME).apk |
michael@0 | 91 | |
michael@0 | 92 | GENERATED_DIRS += $(dir-tests) |
michael@0 | 93 | |
michael@0 | 94 | # The test APK needs to know the contents of the target APK while not |
michael@0 | 95 | # being linked against them. This is a best effort to avoid getting |
michael@0 | 96 | # out of sync with base's build config. |
michael@0 | 97 | JARS_DIR := $(DEPTH)/mobile/android/base |
michael@0 | 98 | JAVA_BOOTCLASSPATH := $(JAVA_BOOTCLASSPATH):$(subst $(NULL) ,:,$(wildcard $(JARS_DIR)/*.jar)) |
michael@0 | 99 | # We also want to re-compile classes.dex when the associated base |
michael@0 | 100 | # content changes. |
michael@0 | 101 | classes.dex: $(wildcard $(JARS_DIR)/*.jar) |