• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
FizzBuzzではじめるテスト
 

FizzBuzzではじめるテスト

on

  • 9,517 views

2011/07/22 第1回関西PHP勉強会

2011/07/22 第1回関西PHP勉強会

Statistics

Views

Total Views
9,517
Views on SlideShare
2,953
Embed Views
6,564

Actions

Likes
2
Downloads
8
Comments
0

13 Embeds 6,564

http://www.1x1.jp 6243
http://bimi.jpn.com 151
http://www.kphpug.jp 81
http://webcache.googleusercontent.com 42
http://infra.rrdtool.net 20
http://feeds.feedburner.com 11
http://cache.yahoofs.jp 4
http://translate.googleusercontent.com 4
http://www.slideshare.net 3
http://cakephp.inop.info 2
http://cache.baidu.com 1
http://cc.bingj.com 1
https://translate.googleusercontent.com 1
More...

Accessibility

Upload Details

Uploaded via as Apple Keynote

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n

FizzBuzzではじめるテスト FizzBuzzではじめるテスト Presentation Transcript

  • • @shin1x1 / http://iplus.im/shin1x1• ו Shin x blog http://www.1x1.jp/blog/• PHP / Goolge+ / / MotoGP
  • ••
  • 1. FizzBuzz2.3.4. Selenium IDE5. SimpleTest6.
  • • 1 100• 3 Fizz 5 Buzz 3 5 FizzBuzz
  • <?phpclass FizzbuzzController extends AppController { public $uses = array(); public function index() { for ($i = 1 ; $i <= 100 ; $i++) { if ($i % 3 === 0 && $i % 5 === 0) { echo FizzBuzz<br />; } else if ($i % 3 === 0) { echo Fizz<br />; } else if ($i % 5 === 0) { echo Buzz<br />; } else { echo $i.<br />; } } exit; }}
  • • Selenium IDE• SimpleTest 1.0.1• CakePHP 1.3.10• https://github.com/shin1x1/CakePHP-FizzBuzz
  • • Web• Firefox••
  • • ATND• / /• Twitter tweet
  • • PHP• PHPUnit• CakePHP• CakePHP PHPUnit
  • • SimpleTest•
  • ••• ok ng
  • $ret = Calc::double(3);• Calc::double()•
  • $ret = Calc::double(3);$this->assertIdentical(6, $ret);• Calc::double(3) 6• 6 === $ret• ok ng
  • assertIdentical($a, $b); $a === $b assertEqual($a, $b); $a == $b assertTrue($b); (boolean)$b assertFalse($b); !(boolean)$b assertNull($b); !isset($b)
  • assertBodyTextassertTextPresent assertValue value assertLocation URL assertCookie Cookie
  • assertAlert assertAlertNotPresent assertAlertPresent assertAllButtons assertAllFields assertAllLinks assertAllWindowIdsassertAllWindowNames assertAllWindowTitles assertAttribute assertAttributeFromAllWindows assertBodyTextassertChecked assertConfirmation assertConfirmationNotPresent assertConfirmationPresent assertCookieassertCookieByName assertCookieNotPresent assertCookiePresent assertCursorPosition assertEditableassertElementHeight assertElementIndex assertElementNotPresent assertElementPositionLeft assertElementPositionTopassertElementPresent assertElementWidth assertEval assertExpression assertHtmlSource assertLocationassertMouseSpeed assertNotAlert assertNotAllButtons assertNotAllFields assertNotAllLinks assertNotAllWindowIdsassertNotAllWindowNames assertNotAllWindowTitles assertNotAttribute assertNotAttributeFromAllWindowsassertNotBodyText assertNotChecked assertNotConfirmation assertNotCookie assertNotCookieByNameassertNotCursorPosition assertNotEditable assertNotElementHeight assertNotElementIndexassertNotElementPositionLeft assertNotElementPositionTop assertNotElementWidth assertNotEval assertNotExpressionassertNotHtmlSource assertNotLocation assertNotMouseSpeed assertNotOrdered assertNotPromptassertNotSelectOptions assertNotSelected assertNotSelectedId assertNotSelectedIds assertNotSelectedIndexassertNotSelectedIndexes assertNotSelectedLabel assertNotSelectedLabels assertNotSelectedValueassertNotSelectedValues assertNotSomethingSelected assertNotSpeed assertNotTable assertNotText assertNotTitleassertNotValue assertNotVisible assertNotWhetherThisFrameMatchFrameExpressionassertNotWhetherThisWindowMatchWindowExpression assertNotXpathCount assertOrdered assertPromptassertPromptNotPresent assertPromptPresent assertSelectOptions assertSelectedId assertSelectedIds assertSelectedIndexassertSelectedIndexes assertSelectedLabel assertSelectedLabels assertSelectedValue assertSelectedValuesassertSomethingSelected assertSpeed assertTable assertText assertTextNotPresent assertTextPresent assertTitleassertValue assertVisible assertWhetherThisFrameMatchFrameExpressionassertWhetherThisWindowMatchWindowExpression assertXpathCount
  • assertAlert assertAlertNotPresent assertAlertPresent assertAllButtons assertAllFields assertAllLinks assertAllWindowIds assertAllWindowNamesassertAllWindowTitles assertAttribute assertAttributeFromAllWindows assertBodyText assertChecked assertConfirmation assertConfirmationNotPresentassertConfirmationPresent assertCookie assertCookieByName assertCookieNotPresent assertCookiePresent assertCursorPosition assertEditable assertElementHeightassertElementIndex assertElementNotPresent assertElementPositionLeft assertElementPositionTop assertElementPresent assertElementWidth assertEvalassertExpression assertHtmlSource assertLocation assertMouseSpeed assertNotAlert assertNotAllButtons assertNotAllFields assertNotAllLinks assertNotAllWindowIdsassertNotAllWindowNames assertNotAllWindowTitles assertNotAttribute assertNotAttributeFromAllWindows assertNotBodyText assertNotCheckedassertNotConfirmation assertNotCookie assertNotCookieByName assertNotCursorPosition assertNotEditable assertNotElementHeight assertNotElementIndexassertNotElementPositionLeft assertNotElementPositionTop assertNotElementWidth assertNotEval assertNotExpression assertNotHtmlSource assertNotLocationassertNotMouseSpeed assertNotOrdered assertNotPrompt assertNotSelectOptions assertNotSelected assertNotSelectedId assertNotSelectedIdsassertNotSelectedIndex assertNotSelectedIndexes assertNotSelectedLabel assertNotSelectedLabels assertNotSelectedValue assertNotSelectedValuesassertNotSomethingSelected assertNotSpeed assertNotTable assertNotText assertNotTitle assertNotValue assertNotVisibleassertNotWhetherThisFrameMatchFrameExpression assertNotWhetherThisWindowMatchWindowExpression assertNotXpathCount assertOrdered assertPromptassertPromptNotPresent assertPromptPresent assertSelectOptions assertSelectedId assertSelectedIds assertSelectedIndex assertSelectedIndexes assertSelectedLabelassertSelectedLabels assertSelectedValue assertSelectedValues assertSomethingSelected assertSpeed assertTable assertText assertTextNotPresent assertTextPresentassertTitle assertValue assertVisible assertWhetherThisFrameMatchFrameExpression assertWhetherThisWindowMatchWindowExpression assertXpathCountverifyErrorOnNext verifyNotErrorOnNext verifyFailureOnNext verifyNotFailureOnNext verifySelected verifyNotSelected verifyAlert verifyNotAlert verifyAllButtonsverifyNotAllButtons verifyAllFields verifyNotAllFields verifyAllLinks verifyNotAllLinks verifyAllWindowIds verifyNotAllWindowIds verifyAllWindowNamesverifyNotAllWindowNames verifyAllWindowTitles verifyNotAllWindowTitles verifyAttribute verifyNotAttribute verifyAttributeFromAllWindowsverifyNotAttributeFromAllWindows verifyBodyText verifyNotBodyText verifyConfirmation verifyNotConfirmation verifyCookie verifyNotCookie verifyCookieByNameverifyNotCookieByName verifyCursorPosition verifyNotCursorPosition verifyElementHeight verifyNotElementHeight verifyElementIndex verifyNotElementIndexverifyElementPositionLeft verifyNotElementPositionLeft verifyElementPositionTop verifyNotElementPositionTop verifyElementWidth verifyNotElementWidth verifyEvalverifyNotEval verifyExpression verifyNotExpression verifyHtmlSource verifyNotHtmlSource verifyLocation verifyNotLocation verifyMouseSpeed verifyNotMouseSpeedverifyPrompt verifyNotPrompt verifySelectedId verifyNotSelectedId verifySelectedIds verifyNotSelectedIds verifySelectedIndex verifyNotSelectedIndexverifySelectedIndexes verifyNotSelectedIndexes verifySelectedLabel verifyNotSelectedLabel verifySelectedLabels verifyNotSelectedLabels verifySelectedValueverifyNotSelectedValue verifySelectedValues verifyNotSelectedValues verifySelectOptions verifyNotSelectOptions verifySpeed verifyNotSpeed verifyTable verifyNotTableverifyText verifyNotText verifyTitle verifyNotTitle verifyValue verifyNotValue verifyWhetherThisFrameMatchFrameExpressionverifyNotWhetherThisFrameMatchFrameExpression verifyWhetherThisWindowMatchWindowExpression verifyNotWhetherThisWindowMatchWindowExpressionverifyXpathCount verifyNotXpathCount verifyAlertPresent verifyAlertNotPresent verifyChecked verifyNotChecked verifyConfirmationPresentverifyConfirmationNotPresent verifyCookiePresent verifyCookieNotPresent verifyEditable verifyNotEditable verifyElementPresent verifyElementNotPresentverifyOrdered verifyNotOrdered verifyPromptPresent verifyPromptNotPresent verifySomethingSelected verifyNotSomethingSelected verifyTextPresentverifyTextNotPresent verifyVisible verifyNotVisible
  • • OK = GREEN• NG = RED
  • 1.2.3.4.
  • • SimpleTest http://www.simpletest.org/• Selenium IDE http://seleniumhq.org/projects/ide/• CakePHP http://cakephp.org/