Skip to content

Instantly share code, notes, and snippets.

@onigra
Last active November 1, 2019 03:07
Show Gist options
  • Save onigra/7244008 to your computer and use it in GitHub Desktop.
Save onigra/7244008 to your computer and use it in GitHub Desktop.
非エンジニア向けselenium導入レクチャー

seleniumとは?

ブラウザでの動作確認を自動化してくれるツール
使用できるのはFirefoxのみ

インストール

  • 最短

下記をクリック
http://release.seleniumhq.org/selenium-ide/2.4.0/selenium-ide-2.4.0.xpi

  • 通常
  1. Firefoxを開く

  2. ダウンロードページにアクセス

www.seleniumhq.org/download/

  1. Selenium IDEのバージョン番号が書いてある所をクリック(今だと2.4)

  2. インストールして再起動

テストケース作成

  • 会員ページにログインするテスト

  • ログインしているのが自分か確認するテスト

    assertTextPresent: ページ内に特定の文字列があるかを確認する

assert、verifyの違い

assertは結果がfalseだった際にテストの実行が止まる
verifyはfalseが発生しても最後まで実行する

コマンドリファレンス

古い記事なので注意
http://szk-takanori.hatenablog.com/entry/20060611/1150028429

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment