0
I am trying to run robotium using ANT build but it giving error : 

//The code to select the text using the robotium .

import com.android.uiautomator.core.UiObject;
import com.android.uiautomator.core.UiObjectNotFoundException;
import com.android.uiautomator.core.UiScrollable;
import com.android.uiautomator.core.UiSelector;
import android.webkit.WebView;
import com.android.uiautomator.testrunner.UiAutomatorTestCase;
import com.jayway.android.robotium.solo.Solo;

UiObject policy = new UiObject(new UiSelector().className(
        "android.widget.TextView").textContains(t_o_s));
policy.clickAndWaitForNewWindow();
solo.clickOnText("Privacy Policy");

-pre-compile:

compile:
    [javac] Compiling 6 source files to C:\eclipse\NewClientAutomation\bin\clas
es
    [javac] C:\eclipse\NewClientAutomation\src\com\android\test\ca\AhaTest.java
18: error: package com.jayway.android.robotium.solo does not exist
    [javac] import com.jayway.android.robotium.solo.Solo;
    [javac]                                        ^
    [javac] C:\eclipse\NewClientAutomation\src\com\android\test\ca\AhaTest.java
40: error: cannot find symbol
    [javac]     private Solo solo ;
    [javac]             ^
    [javac]   symbol:   class Solo
    [javac]   location: class AhaTest
    [javac] 2 errors

BUILD FAILED


Please provide me the solution. how to include robotium class into the ANT.

如何在 ANT 中配置构建路径以包含 robots.class 文件。我正在使用 Uiautoamator 屏幕截图功能来截取屏幕并放置机器人独奏类来选择网页视图页面中的文本。我想使用 ANT Build 在 uiautomator 中使用 robotsium 类。

4

0 回答 0