小编cyc*_*115的帖子

android espresso测试:空测试套件.没有发现任何测试

我正在windows上运行intelliJ idea 14.0.2 android开发环境,我正在尝试使用espresso UI测试框架来测试我的app.However当我按下运行androidTest配置时,我遇到以下情况:

Testing started at 12:09 PM ...
Waiting for device.
Target device: lge-nexus_5-05b1bd8af0ddba12
Uploading file
local path: C:\Users\AsiAnSeNsAtIoN\Documents\note\ECSE428\AssB_2\build\classes\main\AssB_2.apk
remote path: /data/local/tmp/com.cyc115.VectorCalculator
Installing com.cyc115.VectorCalculator
DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/com.cyc115.VectorCalculator"
pkg: /data/local/tmp/com.cyc115.VectorCalculator
Success

Running tests
Test running startedFinish
Empty test suite.
Run Code Online (Sandbox Code Playgroud)

这是截图: 在此输入图像描述

我的测试类看起来像这样:

package com.cyc115.VectorCalculator.test;

import android.support.test.espresso.assertion.ViewAssertions;
import android.test.ActivityInstrumentationTestCase2;
import android.test.suitebuilder.annotation.LargeTest;
import android.test.suitebuilder.annotation.SmallTest;
import com.cyc115.VectorCalculator.MyActivity;

import static android.support.test.espresso.Espresso.onView;
import static android.support.test.espresso.matcher.ViewMatchers.isDisplayed;
import static android.support.test.espresso.matcher.ViewMatchers.withText;

@LargeTest
public class MyActivityTest extends ActivityInstrumentationTestCase2<MyActivity> {

    public MyActivityTest(){
        super (MyActivity.class);
    } …
Run Code Online (Sandbox Code Playgroud)

android intellij-idea ui-testing gradle android-espresso

9
推荐指数
1
解决办法
3686
查看次数

OpenTok 抓取订阅者视频流的屏幕截图

我想知道如何获取订阅者视频提要的屏幕截图。我看到一个表示视频流的 Stream 对象被传递到订阅者的构造函数中,但我不知道如何利用它来将当前帧转换为位图。和想法?

提前致谢 !

mobile android video-streaming webrtc opentok

5
推荐指数
1
解决办法
2380
查看次数

OCaml这不是函数;它不能被应用

num_order rank -> int定义了一个函数。

以下函数调用将导致错误

let dom_rank r1 r = (num_order r1) > (num_order r)
dom_rank Seven Eight
Run Code Online (Sandbox Code Playgroud)

第1行:错误:此表达式的类型为int

  This is not a function; it cannot be applied.
Run Code Online (Sandbox Code Playgroud)

它似乎是导致问题的第一行...但是,当我删除第二行时,错误消失了。

ocaml functional-programming

3
推荐指数
1
解决办法
6128
查看次数

$ @和$*之间的区别

我已经写了一个简单的脚本,需要在任意数量的参数来证明之间的区别$@$*:

#!/bin/bash                                                                
echo "double quoted $*     $@"
echo 'single quoted $*     $@'
Run Code Online (Sandbox Code Playgroud)

我在CLI上做了

$./stuff.sh a b c d e f dfs 
Run Code Online (Sandbox Code Playgroud)

这就是打印出来的东西

double quoted a b c d e f dfs     a b c d e f dfs
single quoted $*     $@
Run Code Online (Sandbox Code Playgroud)

既然它们是相同的那么意味着$@等于$*?还是有一点我错过了?

parameters bash command-line-interface

2
推荐指数
1
解决办法
3128
查看次数