Appium with PHPUnit - short version -

Appium with PHPUnit - short version -

Appium is Mobile App Test Tool.
How to use Appium by PHPUnit.

8e528456ff66ec543952daa815353a01?s=128

Norio Suzuki

July 15, 2013
Tweet

Transcript

  1. "QQJVNXJUI1)16OJU TIPSUWFSTJPO !TV[VLJ  1)1.BUTVSJ4BQQPSP B 13೥7݄15೔݄༵೔

  2. B "CPVUNF w5XJUUFS!TV[VLJ w(JU)VC 7JNFP 6TUSFBNTV[VLJ w8FC/JLLJIUUQTV[VLJUEJBSZOFU IUUQHJIZPKQMJGFTUZMFTFSJBMFWFOUTUSFBNJOH 13೥7݄15೔݄༵೔

  3. 13೥7݄15೔݄༵೔

  4. B .FNCFSPG$BLF1)1(JU)VC https://github.com/cakephp?tab=members #VU POMZDBOQVTIEPDSFQP 13೥7݄15೔݄༵೔

  5. B "CPVUUIJTTFTTJPO 13೥7݄15೔݄༵೔

  6. B "QQJVN http://appium.io/ 13೥7݄15೔݄༵೔

  7. B 4UFQT w4UFQ w 4FUUJOHJ044JNVMBUPS w4UFQ w 4FUUJOH)PNFCSFX /PEFKT w4UFQ

    w 4FUUJOH"QQJVN w4UFQ w 4FUUJOH1)1DPNQPOFOUT 13೥7݄15೔݄༵೔
  8. 0WFSWJFX .BD049 1)1 "QQJVN J044JNVMBUPS 4BVDFa4BVTBHFa8FC%SJWFS5FTU$BTF FYUFOEFE 1)16OJU@&YUFOTJPOT@4FMFOJVN5FTU$BTF 1)16OJU 13೥7݄15೔݄༵೔

  9. B 4UFQ 4FUUJOHJ044JNVMBUPS 13೥7݄15೔݄༵೔

  10. B *OTUBMMJ044JNVMBUPS w%PXOMPBE9DPEFGSPN.BD"QQ4UPSF w4LJQUIJT JOUIJTUBML 13೥7݄15೔݄༵೔

  11. B 4UFQ 4FUUJOH)PNFCSFX /PEFKT 13೥7݄15೔݄༵೔

  12. )PNFCSFX w5IFNJTTJOHQBDLBHFNBOBHFSGPS049 • http://mxcl.github.io/homebrew/ w*OTUBMM • ruby -e "$(curl -fsSL

    https://raw.github.com/mxcl/homebrew/go)" Homebrew B 13೥7݄15೔݄༵೔
  13. /PEFKT w'PSFBTJMZCVJMEJOHGBTU TDBMBCMFOFUXPSL BQQMJDBUJPOT w IUUQOPEFKTPSH B 13೥7݄15೔݄༵೔

  14. B *OTUBMM/PEFKT w#Z)PNFCSFX • $ brew install node w"OPUIFSXBZ CZQBDLBHFPSUBSCBMM

    w :PVDBOHFUCJOBSJFTCZhttp://nodejs.org/download/ 13೥7݄15೔݄༵೔
  15. B 4UFQ 4FUUJOH"QQJVN 13೥7݄15೔݄༵೔

  16. B *OTUBMM"QQJVN w*OTUBMMCZOQN OPEFQBDLBHFNBOBHFS • $ npm install appium w

    OPVTFH HMPCBM PQUJPOJOUIJTDBTF w3FTVMUTBNQMF $ npm install appium npm http GET https://registry.npmjs.org/appium npm http 304 https://registry.npmjs.org/appium npm http GET https://registry.npmjs.org/underscore [snip] appium@0.8.0 ../../node_modules/appium ├── path@0.4.9 ├── win-spawn@1.1.2 ├── bufferpack@0.0.6 ├── colors@0.6.0-1 ├── through@2.3.4 ├── uuid-js@0.7.4 [snip] └── socket.io@0.9.16 (base64id@0.1.0, policyfile@0.0.4, redis@0.7.3, socket.io- client@0.9.16) 13೥7݄15೔݄༵೔
  17. B 3VO w8IFSFXBTJUJOTUBMMFE • $HOME/node_modules/appium/ (many files) • $HOME/node_modules/.bin/appium (symlink

    to run) w"EE1"5) • $ export PATH=$PATH:$HOME/node_modules/.bin 13೥7݄15೔݄༵೔
  18. B "VUIPSJ[FJ04%FWJDF w"VUIPSJ[FJ04EFWJDF • $ sudo authorize_ios $ sudo authorize_ios

    Password: Backed up to /tmp/authorization.backup.113611-37040-1twmqvz Check this diff to make sure the change looks cool: *** before --- after *************** *** 8232,8238 **** $ $ <key>system.privilege.taskport</key> $ $ <dict> $ $ $ <key>allow-root</key> ! $ $ $ <false/> $ $ $ <key>class</key> $ $ $ <string>user</string> $ $ $ <key>comment</key> --- 8232,8238 ---- $ $ <key>system.privilege.taskport</key> $ $ <dict> $ $ $ <key>allow-root</key> ! $ $ $ <true/> $ $ $ <key>class</key> $ $ $ <string>user</string> $ $ $ <key>comment</key> prompt: Make changes? [y/n] : y Wrote new /etc/authorization Authorization successful 13೥7݄15೔݄༵೔
  19. B 3VO"QQJVN w3VO • $ appium 13೥7݄15೔݄༵೔

  20. B 4UFQ 4FUUJOH1)1DPNQPOFOUT 13೥7݄15೔݄༵೔

  21. $PNQPTFS w%FQFOEFODZ .BOBHFSGPS1)1 w IUUQHFUDPNQPTFSPSH B 13೥7݄15೔݄༵೔

  22. B *OTUBMM$PNQPTFS w(FU$PNQPTFS • $ curl -sS https://getcomposer.org/installer | php

    -d detect_unicode=off 13೥7݄15೔݄༵೔
  23. B (FUDPNQPTFSKTPO w(FUDPNQPTFSKTPOGSPN(JU)VC • $ cd YOUR_DIRECTORY • $ wget

    https://raw.github.com/appium/appium/master/ sample-code/examples/php/composer.json w 5IJTJTTBNQMFpMFNBEFCZ"QQJVNQSPKFDU w*OTUBMMVTJOH$PNQPTFS • $ ./composer.phar install 13೥7݄15೔݄༵೔
  24. B *OTJEF$PNQPTFSKTPO w0OMZUIFGPMMPXJOH { "require": { "sauce/sausage": ">=0.6.0" } }

    13೥7݄15೔݄༵೔
  25. B *OTUBMMTBVDFTBVTBHF w6TJOH$PNQPTFS • $ ./composer.phar install 13೥7݄15೔݄༵೔

  26. B *OTUBMMSFTVMUT w*OTUBMMFETBVDFTBVTBHF BOEQIQVOJU QIQVOJUTFMFOJVN Loading composer repositories with package

    information Installing dependencies (including require-dev) [snip] - Installing phpunit/phpunit (3.7.22) Downloading: 100% [snip] - Installing phpunit/phpunit-selenium (1.3.1) Downloading: 100% [snip] - Installing sauce/sausage (v0.9.0) Downloading: 100% No Sauce config file found. Please run vendor/bin/sauce_config USERNAME API_KEY symfony/console suggests installing symfony/event-dispatcher () phpunit/php-code-coverage suggests installing ext-xdebug (>=2.0.5) phpunit/phpunit suggests installing phpunit/php-invoker (>=1.1.0,<1.2.0) sauce/sausage suggests installing sauce/connect (>=3.0) Writing lock file Generating autoload files 13೥7݄15೔݄༵೔
  27. B /BUJWF"QQ%FNP 13೥7݄15೔݄༵೔

  28. B 5BSHFU"QQ 13೥7݄15೔݄༵೔

  29. B 4BNQMF$PEFpSTUIBMG  13೥7݄15೔݄༵೔

  30. B 4BNQMF$PEFMBTUIBMG 13೥7݄15೔݄༵೔

  31. B 3FGFSFODFT 13೥7݄15೔݄༵೔

  32. B 1)16OJUEPDVNFOU • http://www.phpunit.de/manual/3.7/ja/selenium.html#selenium.selenium2testcase 13೥7݄15೔݄༵೔

  33. B 4FMFOJVN8JLJ • http://code.google.com/p/selenium/w/list 13೥7݄15೔݄༵೔

  34. B 5IF8FC%SJWFS8JSF1SPUDPM • http://code.google.com/p/selenium/wiki/JsonWireProtocol 13೥7݄15೔݄༵೔

  35. B .ZXPSLJOHEPDVNFOU • http://bit.ly/phpunit-selenium2 13೥7݄15೔݄༵೔

  36. B ඼࣭޲্ϒϩά • http://blog.trident-qa.com/2013/05/so-many-seleniums/ 5IJTCMPHJTOPUNJOF 13೥7݄15೔݄༵೔

  37. B &YUFOEFE 13೥7݄15೔݄༵೔

  38. B 4BVDF-BCT •https://saucelabs.com/ 13೥7݄15೔݄༵೔

  39. B 5IBOLT 13೥7݄15೔݄༵೔