Running feature specs with Capybara and Chrome headless July 05, 2017 – Tim Petricola – 2-minute read This article was written before Drivy was acquired by Getaround, and became Getaround EU. Some references to Drivy may therefore remain in the post At Drivy, we’ve been using Capybara and PhantomJS to run our feature specs for years. Even with its issues, PhantomJS is a great way to interact with
Run this test once, and VCR will record the HTTP request to fixtures/vcr_cassettes/synopsis.yml. Run it again, and VCR will replay the response from iana.org when the HTTP request is made. This test is now fast (no real HTTP requests are made anymore), deterministic (the test will continue to pass, even if you are offline, or iana.org goes down for maintenance) and accurate (the response will cont
Introduction In this tutorial, we’ll cover how to do integration tests in Rails using Minitest and Capybara. We’ll also cover how integration tests can sometimes serve as a replacement for controller tests. Prerequisites To follow this tutorial, you’ll need to have Ruby installed along with Rails. This tutorial was tested using Ruby version 2.3.3, Rails version 5.0.0.1, Minitest version 5.10.1, an
Web scraping is an approach for extracting data from websites that don’t have an API. Web scraping code is inherently “brittle” (prone to breaking over time due to changes in the website content and structure), but it’s a flexible technique with a broad range of uses. This tutorial will show you how to scrape websites with Ruby and the Poltergeist gem, a PhantomJS driver for Capybara. Getting star
Using Selenium with Ruby 29 Jul 2016 Why? Selenium-WebDriver with Ruby is of the most powerful tools I have used to test web servers through the browser and automate any kind of repetitive web tasks. It is also how I discovered outside in testing. Selenium and Ruby is a great way to automate client tasks for a web server. Debugging is easier as well, because you can see the script run in the brows
If you’re a Ruby or Rails developer looking for some advice on how to get better at integration testing: congratulations! You’ve reached the highest level of difficulty in all of the areas of the stack you must conquer to become a great Ruby developer. Integration testing is hard, but it doesn’t have to be. This the subtle of this truth lies in the fact that you must be skilled in both the backend
はじめまして、開発部で技術基盤を担当しているid:Yasaichiです。 乃木坂46の橋本奈々未さんを推しすぎて、デスクに雑誌の切り抜きを飾っています。 本エントリでは、先日行った技術改善の取り組みについて紹介したいと思います。 はじめに PIXTAは、「本体」と呼ばれるモノリシックなRailsアプリケーションと、そこから切りだされた複数のマイクロサービスで構成されています。 現在、これらの中で、Rails 5のリリースによって完全にサポートが切れる4.1系(とそれ以下)で動作しているアプリケーションのバージョンアップを計画しています。 This means 4.1.x and below will essentially be unsupported! Rails 5.0.0.beta1: Action Cable, API mode, Rails command | Riding Ra
If you use Docker to deploy your Rails application you may want to use the same infrastructure to run your tests. However the setup of your Selenium browser tests is far from obvious with Rails and Docker and may generate some confusion 1 2 3 4 5. The short answer is available in this repository on Github. For the long answer keep reading this blog post for a step by step tutorial! Dockerize Rails
はじめに 3月頃,『【Rails】RSpecでWeb APIのテストでハマったところ①』という初心者丸出しな記事を書きました. あれから9ヶ月ほど,お仕事としてRailsに触れたりしたため知見・スキルも向上してきたと思います. そして今,前述の記事を見直したところ恥ずかしくて顔を覆いたくなる感じになったので改めてWeb APIのテストについて書いていきます. APIのテスト? そもそもWeb APIのテストはどこに書くの?ってところからですが… Controller SpecではなくRequest Specに書いていきます. Use RSpec Request Specs Since we’ve established that we’ll be using Rack::Test to drive the tests, RSpec request specs make the most s
ウェブアプリケーションを開発する際、みなさんはどのように動作確認(試験)を行っていますか? ウェブアプリケーションは、ユーザーごとに異なるブラウザを使用しており、ユーザー操作も必要となるため、手作業でテストをされている方も多いと思います。また、機能改修やバグフィクス後に、リグレッションテスト(改修により既存機能への影響がないかを確認する回帰テスト)が必要となりますが、時間が取れず試験ができていない方も多いのではないでしょうか。 本記事では、これらのテストを自動化することのできる「Selenium Webdriver」(セレニウム・ウェブドライバー)について紹介します。 入力フォームのバリデーション機能をチェックするデモ 簡単な入力フォームのバリデーション機能をチェックするデモを動画で紹介しましょう。入力値に対して期待するエラー文言が表示されているかのテストを実施しています。Selenium
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く