Railsware Blog

on product management, engineering, design, culture and many more...

Debugging Capybara: screenshot of error page on CircleCI

Debugging Capybara: screenshot of error page on CircleCI

Having real screenshot of a failed integration spec can save hours of debugging. We had screenshot with error on the local development environment, and wanted to have it on Continuous Integration server. Luckily for us, it’s a real no-brainer, if you use CircleCI. There is no need for custom S3 …

Responsive layout tests with Capybara and RSpec

Responsive layout tests with Capybara and RSpec

Responsive web design is not a feature these days, bur rather a must. So, while implementing responsive layout in your application, you might find helpful adding verifications to your acceptance tests and ensure accessibility/inaccessibility to your app functionality depending on the screen size. Capybara has a method to resize the …

Flexbox as a solution for browser reflow optimization

Flexbox as a solution for browser reflow optimization

While we’ve been developing one of our products (Mailtrap), we needed to create 2 column page layout with inner blocks stretching down to the whole height of browser window with sticky footer and header. The page layout looks like this: This layout has several nesting levels which makes it more complicated …

Make AngularJS 1.0.7 work with Jasmine 2.0

Make AngularJS 1.0.7 work with Jasmine 2.0

During setup of Jasmine 2.0 for AngularJS 1.0.7 application it turned out that they are not compatible. The reason is that Angular 1.0.7 is compatible with the older version of Jasmine – 1.3. And there were several breaking changes in Jasmine private API which was used by AngularJS. There were …

Rails logging into several backends

Rails logging into several backends

Sometimes, it’s required to setup Rails logger for storing logs into several backends. In our case we decided to use Loggly, but also wanted to leave old file-based logging. Despite the actual solution is very simple, it’s hard to find it. The best match on StackOverflow suggests to create some …

Creating custom HTML elements with Web Components

Creating custom HTML elements with Web Components

Web Components Web Components are a collection of standards which are currently actively supported by google and mozilla teams. The core idea is that they allow us to bundle markup, styles and javascript functionality into custom HTML elements. And great thing about these new elements is that they fully encapsulate …

Share Rails configuration to Javascript

Share Rails configuration to Javascript

The usual way of storing Rails configuration data are YAML files. In one of our previous posts, we talked about proper way of dealing with Rails configuration. Nowadays, Javascript applications built on top of RESTful API are common practice, and in cases like this configuration data might be duplicated across …

BDD-style testing in Swift with Sleipnir

BDD-style testing in Swift with Sleipnir

Introduction In Objective-C people use different frameworks to write BDD-style tests for their code. Some of them are: Cedar Kiwi Specta With the inroduction of Swift we’ve decided to create BDD-style testing framework in pure Swift. After a couple weeks of implementation we are making the first public version of …