{"id":255788,"date":"2015-04-22T13:36:02","date_gmt":"2015-04-22T09:36:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=255788"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=255788","title":{"rendered":"\u041a\u043e\u0444\u0435 \u0441 \u043e\u0433\u0443\u0440\u0446\u0430\u043c\u0438 (Espresso + Cucumber)"},"content":{"rendered":"<p>     \t<img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/e8e\/475\/443\/e8e4754438614a109dda5fd6e8438d1e.png\"\/><\/p>\n<p>  &nbsp;&nbsp;&nbsp;&nbsp;\u041e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435 \u0442\u0430\u043a \u0434\u0430\u0432\u043d\u043e \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Espresso \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f UI Android \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u0415\u0451 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u043d\u0430\u0434 \u0430\u043d\u0430\u043b\u043e\u0433\u0430\u043c\u0438 \u043e\u0431\u043e\u0437\u0440\u0435\u0432\u0430\u043b\u0438\u0441\u044c \u043d\u0435 \u043e\u0434\u0438\u043d \u0440\u0430\u0437. \u0415\u0441\u043b\u0438 \u0432\u043a\u0440\u0430\u0442\u0446\u0435, \u0442\u043e \u043e\u043d\u0438 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u044e\u0442\u0441\u044f \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u044d\u0442\u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0430 Google \u0434\u043b\u044f \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0439 \u041e\u0421 (\u0440\u0430\u043d\u0435\u0435 \u043e\u043d\u0438 \u0441\u0430\u043c\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 Robotium), \u0430 \u0442\u0430\u043a \u0436\u0435 \u0432 \u043b\u0430\u043a\u043e\u043d\u0438\u0447\u043d\u043e\u0441\u0442\u0438 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441\u0430 \u0438 \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u0438 \u0440\u0430\u0431\u043e\u0442\u044b. \u0418\u0442\u0430\u043a, \u043c\u044b \u0440\u0435\u0448\u0438\u043b\u0438 \u0438\u0434\u0442\u0438 \u0432 \u043d\u043e\u0433\u0443 \u0441\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Espresso. \u041d\u043e \u043d\u0430\u043c \u043c\u0430\u043b\u043e \u0442\u0435\u0445 \u043f\u043b\u044e\u0441\u043e\u0432, \u0447\u0442\u043e \u0443\u0436\u0435 \u0435\u0441\u0442\u044c, \u043c\u044b \u0445\u043e\u0442\u0438\u043c BDD (<a href=\"http:\/\/en.wikipedia.org\/wiki\/Behavior-driven_development\">http:\/\/en.wikipedia.org\/wiki\/Behavior-driven_development<\/a>), \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u0438 \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0432 json \u0438 html, \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u044d\u0442\u043e \u0432\u0441\u0435 \u043d\u0430 CI, \u0432 \u043a\u043e\u043d\u0446\u0435 \u043a\u043e\u043d\u0446\u043e\u0432! \u041d\u043e \u043e\u0431\u043e \u0432\u0441\u0435\u043c \u043f\u043e \u043f\u043e\u0440\u044f\u0434\u043a\u0443. \u042f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u043a\u0430\u043a \u043f\u043e\u0434\u0440\u0443\u0436\u0438\u0442\u044c Cucumber (<a href=\"http:\/\/habrahabr.ru\/post\/62958\/\">http:\/\/habrahabr.ru\/post\/62958\/<\/a>) \u0438 Espresso(<a href=\"http:\/\/habrahabr.ru\/post\/212425\/\">http:\/\/habrahabr.ru\/post\/212425\/<\/a>) \u043d\u0430 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435. \u0412\u0441\u0435\u0445, \u043a\u0442\u043e \u0443\u0441\u0442\u0430\u043b \u043e\u0442 Appium, \u043a\u0442\u043e \u0445\u043e\u0447\u0435\u0442 \u0443\u0439\u0442\u0438 \u043e\u0442 Robotium \u0438 \u0442\u0435\u0445, \u043a\u043e\u043c\u0443 \u043d\u0435\u0431\u0435\u0437\u0440\u0430\u0437\u043b\u0438\u0447\u043d\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 Android, \u043f\u0440\u043e\u0448\u0443 \u043f\u043e\u0434 \u043a\u0430\u0442. <br \/>  <a name=\"habracut\"><\/a><\/p>\n<p>  <b>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/b><\/p>\n<p>  \u041c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Gradle \u043a\u0430\u043a \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u041e\u0447\u0435\u043d\u044c \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u0434\u043b\u044f \u0442\u0435\u0445, \u043a\u0442\u043e \u0435\u0449\u0435 \u043d\u0435 \u0432\u0438\u0434\u0435\u043b, \u0441\u0430\u0439\u0442 <a href=\"http:\/\/gradleplease.appspot.com\/\">http:\/\/gradleplease.appspot.com\/<\/a>. \u0421\u043e\u043e\u0431\u0449\u0430\u0435\u043c \u0435\u043c\u0443 \u0438\u043c\u044f \u0438\u0441\u043a\u043e\u043c\u043e\u0433\u043e \u043c\u043e\u0434\u0443\u043b\u044f, \u0430 \u043e\u043d \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u0441\u0442\u0440\u043e\u043a\u0443 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0435\u0435 \u0432 Gradle.<\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043f\u0440\u043e\u0435\u043a\u0442 \u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u043c \u043a \u043d\u0435\u043c\u0443 Espresso \u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0434\u043b\u044f \u043d\u0430\u0448\u0435\u0439 \u0437\u0430\u0434\u0430\u0447\u0438 \u043c\u043e\u0434\u0443\u043b\u0438 Cucumber, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0434\u043e\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u0431\u043b\u043e\u043a dependency, \u0444\u0430\u0439\u043b\u0430 build.gradle \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"java\">dependencies {     androidTestCompile('com.jakewharton.espresso:espresso-support-v4:1.1-r3')     androidTestCompile 'info.cukes:cucumber-core:1.1.8'     androidTestCompile 'info.cukes:cucumber-java:1.1.8'     androidTestCompile 'info.cukes:cucumber-html:0.2.3'     androidTestCompile ('info.cukes:cucumber-android:1.2.2')      androidTestCompile ('info.cukes:cucumber-junit:1.1.8')     {         exclude group: 'org.hamcrest', module: 'hamcrest-core'         exclude group: 'org.hamcrest', module: 'hamcrest-integration'         exclude group: 'org.hamcrest', module: 'hamcrest-library'     } } <\/code><\/pre>\n<p>  \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043c\u044b \u043c\u043e\u0433\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430 Espresso, \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e, \u0447\u0442\u043e\u0431\u044b \u0442\u0435\u0441\u0442\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u043b\u0438\u0441\u044c \u0447\u0435\u0440\u0435\u0437 GoogleInstrumentationTestRunner. \u0417\u043d\u0430\u0447\u0438\u0442 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f Cucumber \u043d\u0443\u0436\u043d\u043e \u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0442 \u044d\u0442\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430, \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043c\u044b \u043f\u0435\u0440\u0435\u0434\u0430\u0434\u0438\u043c \u0435\u043c\u0443 \u0432\u0441\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435.<\/p>\n<pre><code class=\"java\">public class CucuRunner extends GoogleInstrumentationTestRunner{     private CucumberInstrumentationCore helper;      public CucuRunner() {         helper = new CucumberInstrumentationCore(this);     }      @Override     public void onCreate(Bundle arguments) {         helper.create(arguments);         super.onCreate(arguments);     }      @Override     public void onStart() {         helper.start();     } } <\/code><\/pre>\n<p>  \u041d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u0435\u043c \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043d\u0430\u0448 \u0441\u0432\u0435\u0436\u0435\u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0439 instrumentation test runner \u0432 build.gradle<\/p>\n<pre><code class=\"java\">defaultConfig {     ...     testInstrumentationRunner 'habrahabr.ru.myapplication.test.CucuRunner'     ...  }   <\/code><\/pre>\n<p>  <b>\u0428\u0430\u0433\u0438 (Steps)<\/b><\/p>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0448\u0430\u0433\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u043d\u0430\u0448\u0438\u0445 \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0445 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445. \u0412 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0438\u043c\u0438 \u0431\u0443\u0434\u0443\u0442 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0435 \u0442\u0435\u0441\u0442\u044b, \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u043d\u044b\u0435 \u0432 \u043e\u0434\u0438\u043d \u043a\u0435\u0439\u0441. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u043a\u043b\u0430\u0441\u0441, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u0441\u043b\u0435\u0434\u0443\u0435\u043c \u043e\u0442 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e \u0434\u043b\u044f Espresso \u043d\u0430\u0431\u043e\u0440\u0430 \u0442\u0435\u0441\u0442\u043e\u0432, \u0434\u0430\u0431\u044b \u0438\u043c\u0435\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a\u043e \u0432\u0441\u0435\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u043c \u0432\u0435\u0449\u0430\u043c. \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u043a \u044d\u0442\u043e\u043c\u0443 \u043a\u043b\u0430\u0441\u0441\u0443 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e, \u0433\u0434\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c, \u0447\u0442\u043e \u044d\u0442\u043e \u0442\u0435\u0441\u0442\u044b Cucumber, \u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0438\u0445 \u0440\u0430\u0431\u043e\u0442\u044b \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u0432 \u043e\u0442\u0447\u0435\u0442\u044b \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u0444\u043e\u0440\u043c\u0430\u0442\u043e\u0432, \u0432 \u043d\u0443\u0436\u043d\u044b\u0435 \u043d\u0430\u043c \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, Espresso-\u0442\u0435\u0441\u0442\u044b \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f \u043d\u0430 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435, \u0438 \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430 \u0443 \u043d\u0430\u0441 \u043d\u0435\u0442. \u0417\u043d\u0430\u0447\u0438\u0442 \u0441\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0435\u043c \u0432\u0441\u0435 \u0432 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f:<\/p>\n<pre><code class=\"java\">@CucumberOptions(format = {&quot;pretty&quot;,&quot;html:\/data\/data\/habrahabr.ru.myapplication\/html&quot;, &quot;json:\/data\/data\/habrahabr.ru.myapplication\/jreport&quot;},features = &quot;features&quot;) public class CucumberActivitySteps extends ActivityInstrumentationTestCase2&lt;MainActivity&gt; { <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u0435\u043c \u0437\u0430\u043d\u044f\u0442\u044c\u0441\u044f \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0435\u0439 \u0448\u0430\u0433\u043e\u0432. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0440\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u044c \u043c\u0435\u0442\u043e\u0434\u044b \u043f\u043e \u0438\u0445 \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044e \u0432 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0438 \u0441 BDD, \u0442\u043e \u0435\u0441\u0442\u044c \u043d\u0430 Given, When \u0438 Then. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0443 \u0434\u043b\u044f \u043d\u0430\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0439 \u0432 \u0444\u0430\u0439\u043b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u044b\u0445 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0439, \u0433\u0440\u0443\u043f\u043f\u044b \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438\u0433\u0440\u0430\u044e\u0442 \u0440\u043e\u043b\u044c \u0432\u0445\u043e\u0434\u043d\u044b\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432, \u0430 \u0432 \u0442\u0435\u043b\u0435 \u0441\u0430\u043c\u0438\u0445 \u0448\u0430\u0433\u043e\u0432 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u044b\u0437\u043e\u0432\u044b Espresso:<\/p>\n<pre><code class=\"java\">    @Given(&quot;^\u0421\u0447\u0435\u0442\u0447\u0438\u043a \u043f\u043e\u043f\u044b\u0442\u043e\u043a \u0432\u0445\u043e\u0434\u0430 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 (\\\\d)$&quot;)     public void givenLoginTryCounter(Integer counterValue) {         String checkString = String.format(getActivity().getResources().getString(R.string.login_try_left), counterValue);         onView(withId(R.id.lblCounter)).check(matches(withText(checkString)));     }      @When(&quot;^\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u0442 \u043a\u043d\u043e\u043f\u043a\u0443 \u043d\u0430\u0437\u0430\u0434$&quot;)     public void clickOnBackButton() {         ViewActions.pressBack();     }      @When(&quot;^\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c '(.+)' \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u0441 \u043f\u0430\u0440\u043e\u043b\u0435\u043c '(.+)'$&quot;)     public void userLogin(String login, String password) {         onView(withId(R.id.txtUsername)).perform(ViewActions.clearText());         onView(withId(R.id.txtPassword)).perform(ViewActions.clearText());          onView(withId(R.id.txtUsername)).perform(ViewActions.typeText(login));         onView(withId(R.id.txtPassword)).perform(ViewActions.typeText(password));         onView(withId(R.id.btnLogin)).perform(ViewActions.click());     }      @Then(&quot;^\u0421\u0447\u0435\u0442\u0447\u0438\u043a \u043f\u043e\u043f\u044b\u0442\u043e\u043a \u0432\u0445\u043e\u0434\u0430 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c (\\\\d)$&quot;)     public void checkLoginTryCounter(Integer counterValue) {         givenLoginTryCounter(counterValue);     }      @Then(&quot;^\u041a\u043d\u043e\u043f\u043a\u0430 \u0432\u0445\u043e\u0434\u0430 \u0441\u0442\u0430\u043b\u0430 \u043d\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0439$&quot;)     public void checkLoginButtonDisabled() {         onView(withId(R.id.btnLogin)).check(matches(not(isEnabled())));     } <\/code><\/pre>\n<p>  <b>\u0421\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b<\/b><\/p>\n<p>  \u0412 \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u043e\u0433\u043e \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044f \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0433\u043e \u0448\u0430\u0433\u0430 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u043d\u0438\u043c\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442 \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043a \u043e\u0442\u0447\u0435\u0442\u0443. \u0412\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u0437\u0430 \u043d\u0430\u0441 \u0441\u0434\u0435\u043b\u0430\u0435\u0442 Cucumber, \u0438 \u043c\u044b \u0441\u043c\u043e\u0436\u0435\u043c \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u044d\u043a\u0440\u0430\u043d\u0430 \u0432 \u043c\u043e\u043c\u0435\u043d\u0442 \u043e\u0448\u0438\u0431\u043a\u0438. \u041f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0434\u0430\u043b\u0435\u0435 \u0441\u043f\u043e\u0441\u043e\u0431 \u043d\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u043b\u044f \u0441\u043d\u044f\u0442\u0438\u044f \u0441\u043d\u0438\u043c\u043a\u0430 \u0441 \u0434\u0438\u0430\u043b\u043e\u0433\u043e\u043c, \u043d\u043e \u044d\u0442\u043e \u0442\u0435\u043c\u0430 \u0434\u043b\u044f \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u0433\u043e\u0432\u043e\u0440\u0430.<\/p>\n<pre><code class=\"java\">@After public void embedScreenshot(Scenario scenario) {     if(scenario.isFailed()) {         Bitmap bitmap;         final Activity activity = getActivity();         View view = getActivity().getWindow().getDecorView();         view.setDrawingCacheEnabled(true);         bitmap = Bitmap.createBitmap(view.getDrawingCache());         view.setDrawingCacheEnabled(false);         ByteArrayOutputStream stream = new ByteArrayOutputStream();         bitmap.compress(Bitmap.CompressFormat.PNG, 100, stream);                 scenario.embed(stream.toByteArray(), &quot;image\/png&quot;);     } } <\/code><\/pre>\n<p>  <b>\u0421\u0446\u0435\u043d\u0430\u0440\u0438\u0438<\/b><\/p>\n<p>  \u041e\u0441\u0442\u0430\u043b\u0430\u0441\u044c \u0441\u0430\u043c\u0430\u044f \u043f\u0440\u0438\u044f\u0442\u043d\u0430\u044f \u0447\u0430\u0441\u0442\u044c. \u0418\u043c\u0435\u044f \u0432 \u0440\u0443\u043a\u0430\u0445 \u0448\u0430\u0433\u0438, \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0435 \u0432 CucumberActivitySteps, \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0430\u043c\u0438 \u0442\u0435\u0441\u0442\u044b \u043d\u0430 \u0447\u0435\u043b\u043e\u0432\u0435\u0447\u0435\u0441\u043a\u043e\u043c \u044f\u0437\u044b\u043a\u0435, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c, \u043d\u043e \u0438 \u0432\u0441\u0435\u043c \u0434\u0440\u0443\u0433\u0438\u043c \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u043b\u0438\u0446\u0430\u043c:<\/p>\n<pre><code class=\"javascript\">    Feature: \u0410\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u044f     Scenario: \u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043d\u0435\u0432\u0435\u0440\u043d\u044b\u0435 \u043b\u043e\u0433\u0438\u043d \u0438 \u043f\u0430\u0440\u043e\u043b\u044c     Given \u0421\u0447\u0435\u0442\u0447\u0438\u043a \u043f\u043e\u043f\u044b\u0442\u043e\u043a \u0432\u0445\u043e\u0434\u0430 \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 3     When \u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c 'RandomName' \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u0441 \u043f\u0430\u0440\u043e\u043b\u0435\u043c 'wrongPassword'     Then \u0421\u0447\u0435\u0442\u0447\u0438\u043a \u043f\u043e\u043f\u044b\u0442\u043e\u043a \u0432\u0445\u043e\u0434\u0430 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c 2     And \u041f\u043e\u044f\u0432\u0438\u043b\u043e\u0441\u044c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 '\u041d\u0435\u0432\u0435\u0440\u043d\u043e\u0435 \u0438\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438\u043b\u0438 \u043f\u0430\u0440\u043e\u043b\u044c.' <\/code><\/pre>\n<p>  \u042d\u0442\u0438 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u043c\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c \u0432 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e features, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043d\u0430\u0448 \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0439 \u043a\u043b\u0430\u0441\u0441 \u0431\u0443\u0434\u0435\u0442 \u0438\u0445 \u0438\u0441\u043a\u0430\u0442\u044c (\u0441\u043c. \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e CucumberOptions).<\/p>\n<p>  <img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/15e\/a3b\/6d8\/15ea3b6d89a44ff3b7cbd2497e3766c7.png\"\/><\/p>\n<p>  <b>\u0418\u0437\u044a\u044f\u0442\u0438\u0435 \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0441 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430<\/b><\/p>\n<p>  \u0415\u0441\u043b\u0438 \u043c\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u0442\u0435\u0441\u0442\u044b, \u043e\u043d\u0438 \u043f\u0440\u043e\u0439\u0434\u0443\u0442, \u043d\u043e \u043e\u0442\u0447\u0435\u0442\u044b \u043e\u0441\u0442\u0430\u043d\u0443\u0442\u0441\u044f \u043b\u0435\u0436\u0430\u0442\u044c \u043d\u0430 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0435. \u0417\u043d\u0430\u0447\u0438\u0442 \u043f\u043e \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438\u0445 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u0442\u0442\u0443\u0434\u0430 \u0437\u0430\u0431\u0440\u0430\u0442\u044c. \u0418\u0434\u0435\u043c \u0432 \u0444\u0430\u0439\u043b build.gradle \u0438 \u043f\u0438\u0448\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 task, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e\u043c \u0443\u0442\u0438\u043b\u0438\u0442\u044b adb \u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u044b pull \u0441\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u0442 \u0444\u0430\u0439\u043b\u044b \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0432 \u0437\u0430\u0434\u0430\u043d\u043d\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e. <\/p>\n<pre><code class=\"java\">task afterTests(type: Exec, dependsOn:runCucuTests) {     commandLine &quot;${android.sdkDirectory}&quot; + &quot;\/platform-tools\/adb&quot;, 'pull', '\/data\/data\/habrahabr.ru.myapplication\/html', System.getProperty(&quot;user.dir&quot;) + &quot;\/cucumber_reports&quot; } <\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u043d\u043e \u0432\u0441\u0435 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0447\u0435\u0440\u0435\u0437 IDE, \u043d\u0443\u0436\u043d\u043e \u043b\u0438\u0448\u044c \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0437\u0430\u043f\u0443\u0441\u043a\u0430, \u0430 \u043f\u043e\u0441\u043b\u0435 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044f \u0442\u0435\u0441\u0442\u043e\u0432 \u0438\u0441\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0430\u0448 task \u0434\u043b\u044f \u0438\u0437\u044a\u044f\u0442\u0438\u044f \u043e\u0442\u0447\u0435\u0442\u043e\u0432. <\/p>\n<p>  <img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/911\/3fd\/499\/9113fd4998214c25ae367f240c7caacb.png\"\/><\/p>\n<p>  \u041e\u0442\u0447\u0435\u0442\u044b \u0436\u0435 \u0431\u0443\u0434\u0443\u0442 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u044b \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u0443\u044e \u0432\u044b\u0448\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e<\/p>\n<p>  <img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/020\/ad9\/247\/020ad9247c734e5fa6aedab3e8b1b979.png\"\/><br \/>  <b>\u0417\u0430\u043f\u0443\u0441\u043a \u043d\u0430 CI<\/b><\/p>\n<p>  \u041d\u043e \u043c\u044b \u043d\u0435 \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0442\u0435\u0441\u0442\u044b \u0447\u0435\u0440\u0435\u0437 IDE, \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0438\u0445 \u0438\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u0438, \u0430 connectedCheck \u043d\u0430\u043c \u043d\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442. \u0417\u043d\u0430\u0447\u0438\u0442 \u043f\u0438\u0448\u0435\u043c \u043d\u043e\u0432\u044b\u0439 task. \u0418 \u0437\u0434\u0435\u0441\u044c \u043c\u044b, \u043a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e, \u043d\u0435 \u043f\u0440\u0438\u0434\u0443\u043c\u0430\u043b\u0438 \u043d\u0438\u0447\u0435\u0433\u043e \u043b\u0443\u0447\u0448\u0435, \u0447\u0435\u043c \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u043d\u0430 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u043e\u0442\u0441\u044b\u043b\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u043d\u0430 \u0441\u0442\u0430\u0440\u0442 \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0447\u0435\u0440\u0435\u0437 adb. \u0410 \u043f\u043e\u0441\u043b\u0435 \u0432\u0441\u0435\u0433\u043e \u044d\u0442\u043e\u0433\u043e \u0437\u0430\u0431\u0438\u0440\u0430\u0442\u044c \u043e\u0442\u0447\u0435\u0442\u044b \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u043c \u0432\u044b\u0448\u0435 task&#8217;\u043e\u043c.<\/p>\n<pre><code class=\"java\">task runCucuTests(type: Exec, dependsOn:'installDebugTest'){     commandLine &quot;${android.sdkDirectory}&quot; + &quot;\/platform-tools\/adb&quot;, 'shell', 'am', 'instrument', '-w', 'habrahabr.ru.myapplication.test\/.CucuRunner', 'echo', 'off'     finalizedBy('afterTests') } <\/code><\/pre>\n<p>  \u0412 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435 \u044d\u0442\u043e\u0433\u043e \u0443\u0436\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0442\u0435\u0441\u0442\u044b \u043d\u0430 CI. <\/p>\n<p>  \u041d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0432\u043e\u0442 \u0442\u0430\u043a\u0438\u0435 \u043e\u0442\u0447\u0435\u0442\u044b:<\/p>\n<p>  <img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/4e1\/b71\/adc\/4e1b71adcdf84fc696dad4042d59a743.png\"\/><\/p>\n<p>  \u0418 \u043a \u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043b\u0441\u044f \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u043e, \u0443 \u043d\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442:<\/p>\n<p>  <img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/6f7\/a98\/4f6\/6f7a984f6e94477eb3ba21879ac5a8e6.png\"\/><\/p>\n<p>  \u041d\u0430 \u044d\u0442\u043e\u043c, \u043f\u043e\u0436\u0430\u043b\u0443\u0439, \u0438 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c\u0441\u044f. \u0417\u0434\u0435\u0441\u044c \u043c\u043d\u043e\u0433\u043e\u0435 \u0435\u0449\u0435 \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0443\u043b\u0443\u0447\u0448\u0438\u0442\u044c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 output \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0442\u0435\u0441\u0442\u043e\u0432, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u043f\u0440\u043e\u0433\u0440\u0435\u0441\u0441\u0435, \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0441 \u043e\u0442\u0447\u0435\u0442\u0430\u043c\u0438 \u043a\u0440\u0430\u0441\u0438\u0432\u044b\u043c \u0438 \u043c\u043d\u043e\u0433\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435. \u041d\u0430\u0434\u0435\u044e\u0441\u044c \u0431\u0443\u0434\u0435\u0442 \u0435\u0449\u0435 \u0442\u0430\u043a\u0430\u044f \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c. \u0414\u043b\u044f \u0432\u0441\u0435\u0445 \u0437\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0441\u0430\u043c \u043f\u0440\u043e\u0435\u043a\u0442 \u0432\u044b\u043b\u043e\u0436\u0435\u043d \u043d\u0430 Github: <a href=\"https:\/\/github.com\/Stabilitron\/espresso-cucumber-example\">https:\/\/github.com\/Stabilitron\/espresso-cucumber-example<\/a><\/p>\n<p>  \u0421\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435. \u0421\u0442\u0430\u0431\u0438\u043b\u044c\u043d\u044b\u0445 \u0432\u0430\u043c \u0440\u0435\u043b\u0438\u0437\u043e\u0432!     \t<\/p>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/255763\/\"> http:\/\/habrahabr.ru\/post\/255763\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>     \t<img decoding=\"async\" src=\"\/\/habrastorage.org\/files\/e8e\/475\/443\/e8e4754438614a109dda5fd6e8438d1e.png\"\/><\/p>\n<p>  &nbsp;&nbsp;&nbsp;&nbsp;\u041e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435 \u0442\u0430\u043a \u0434\u0430\u0432\u043d\u043e \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Espresso \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f UI Android \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u0415\u0451 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u043d\u0430\u0434 \u0430\u043d\u0430\u043b\u043e\u0433\u0430\u043c\u0438 \u043e\u0431\u043e\u0437\u0440\u0435\u0432\u0430\u043b\u0438\u0441\u044c \u043d\u0435 \u043e\u0434\u0438\u043d \u0440\u0430\u0437. \u0415\u0441\u043b\u0438 \u0432\u043a\u0440\u0430\u0442\u0446\u0435, \u0442\u043e \u043e\u043d\u0438 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u044e\u0442\u0441\u044f \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u044d\u0442\u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0430 Google \u0434\u043b\u044f \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0439 \u041e\u0421 (\u0440\u0430\u043d\u0435\u0435 \u043e\u043d\u0438 \u0441\u0430\u043c\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 Robotium), \u0430 \u0442\u0430\u043a \u0436\u0435 \u0432 \u043b\u0430\u043a\u043e\u043d\u0438\u0447\u043d\u043e\u0441\u0442\u0438 \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441\u0430 \u0438 \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u0438 \u0440\u0430\u0431\u043e\u0442\u044b. \u0418\u0442\u0430\u043a, \u043c\u044b \u0440\u0435\u0448\u0438\u043b\u0438 \u0438\u0434\u0442\u0438 \u0432 \u043d\u043e\u0433\u0443 \u0441\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Espresso. \u041d\u043e \u043d\u0430\u043c \u043c\u0430\u043b\u043e \u0442\u0435\u0445 \u043f\u043b\u044e\u0441\u043e\u0432, \u0447\u0442\u043e \u0443\u0436\u0435 \u0435\u0441\u0442\u044c, \u043c\u044b \u0445\u043e\u0442\u0438\u043c BDD (<a href=\"http:\/\/en.wikipedia.org\/wiki\/Behavior-driven_development\">http:\/\/en.wikipedia.org\/wiki\/Behavior-driven_development<\/a>), \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u0438 \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0432 json \u0438 html, \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u044d\u0442\u043e \u0432\u0441\u0435 \u043d\u0430 CI, \u0432 \u043a\u043e\u043d\u0446\u0435 \u043a\u043e\u043d\u0446\u043e\u0432! \u041d\u043e \u043e\u0431\u043e \u0432\u0441\u0435\u043c \u043f\u043e \u043f\u043e\u0440\u044f\u0434\u043a\u0443. \u042f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u043a\u0430\u043a \u043f\u043e\u0434\u0440\u0443\u0436\u0438\u0442\u044c Cucumber (<a href=\"http:\/\/habrahabr.ru\/post\/62958\/\">http:\/\/habrahabr.ru\/post\/62958\/<\/a>) \u0438 Espresso(<a href=\"http:\/\/habrahabr.ru\/post\/212425\/\">http:\/\/habrahabr.ru\/post\/212425\/<\/a>) \u043d\u0430 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435. \u0412\u0441\u0435\u0445, \u043a\u0442\u043e \u0443\u0441\u0442\u0430\u043b \u043e\u0442 Appium, \u043a\u0442\u043e \u0445\u043e\u0447\u0435\u0442 \u0443\u0439\u0442\u0438 \u043e\u0442 Robotium \u0438 \u0442\u0435\u0445, \u043a\u043e\u043c\u0443 \u043d\u0435\u0431\u0435\u0437\u0440\u0430\u0437\u043b\u0438\u0447\u043d\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 Android, \u043f\u0440\u043e\u0448\u0443 \u043f\u043e\u0434 \u043a\u0430\u0442.   <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-255788","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/255788","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=255788"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/255788\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=255788"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=255788"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=255788"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}