How to use MediaMuxerTest (a AndroidTestCase file)

陌路散爱 提交于 2019-12-13 02:17:02

问题


I find demo for MeediaMuxer, which is a AndroidTestCase File. Here is the link.

I never used Android Test. I did some research, but most of them are somehow a little complex... It seems like that I need a xml file, a java file for TestSuite and a java file for AndroidTestCase. And now I have the AndroidTestCase, could anyone tell me how to write the TestSuite? Thank you!


回答1:


From TestSuit overview

A TestSuite is a Composite of Tests. It runs a collection of test cases. Here is an example using the dynamic test definition.

 TestSuite suite= new TestSuite();
 suite.addTest(new MathTest("testAdd"));
 suite.addTest(new MathTest("testDivideByZero"));

Android provide a pretty good documentation for that, tell me if you have more questions after reading it.

Also here is the official article about testing in Android.



来源:https://stackoverflow.com/questions/20878546/how-to-use-mediamuxertest-a-androidtestcase-file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!