Close
Glad You're Ready. Let's Get Started!

Let us know how we can contact you.

Thank you!

We'll respond shortly.

Roberto Ostinelli

Posts By

LABS
[Standup][SF] 5/24 – Don't drink and drivers

Helps

Capybara + Selenium

Using Capybara + Selenium for request tests results in a Rack application timed out during boot which ultimately throws a SystemErrorduring tests.

The single test works fine, the timeout only happens when running a full rake spec.

The same errors appears under these different setups:

  • with Database Cleaner (:truncation strategy)
  • with/without Database Cleaner (:transaction strategy, using shared connection with transactional fixtures [1])

Have tried increasing Capybara.server_boot_timeout = 240 to no avail.

=> Main suggestion is: try with another driver.

[1] http://blog.plataformatec.com.br/2011/12/three-tips-to-improve-the-performance-of-your-test-suite/

IE8 + HTML + JSON

On IE8, refreshing an URL served by a controller which handles both html and json content results in displaying the json instead of the html content.

The json response is only being accessed by an XHR request, which explicitly calls for the URL with the .json extension.

Tried explicitly setting the Content-Type header of json responses (for some reason, not set by rails 3.1), no changes in browser's behaviour.

=> Try inverting the order of the response_to defined in the controller, setting the html as first element.

LABS
[Standup][SF] 5/23 – At the beach

Helps

  • Has anyone seen any failing scenarios when using "contentEditable" with resize set to true, to allow for automatic resizing of textareas?

=> No.

Interestings

  • Range behaviours:
>> range = 1..3
=> 1..3
>> range.first
=> 1
>> range.last
=> 3
>> range.to_a
=> [1, 2, 3]
>> exrange = 1...3
=> 1....3
>> exrange.first
=> 1
>> exrange.last
=> 3
>> exrange.to_a
=> [1, 2]
  • [related] When using Date ranges to define a BETWEEN clause in MySQL, beware that the upper date limit is excluded from the results (1 day less). Unsure about the case when the Date range is exclusive (2 days less?).

  • Lean Startup Machine is coming up!

LABS
[Standup][SF] 5/21 – No Money! ($0)

Helps

chirp chirp

Interestings

  • $0: In Chrome, this command dumps the most recently selected node into the console.

  • RSpec2: If you are used to defining your specs with subject{} and its{} blocks, beware of unexpected results, since the subject changes to whatever is returned by the its blocks.

PIVOTAL LABS
Standup 11/8/2011: Rails 3 fixtures and licenses

Helps

  • Upgrading to Rails 3 from 2.3.14 results in rails not being able to reference named fixtures, so you actually have to force them. For ex:
work_sample_asset_version:
  asset_id: <%= Fixtures.identify(:work_sample_asset) %> # works
  asset: work_sample_asset # doesn't work
  • Ruby license has switched from dual license Ruby License / GPL3 for v1.9.2 to Ruby License / BSD for v1.9.3.

Interesting

  • Riak v1.0 has been released, release party this evening

  • On Lion, Ctrl-F7 allows you to toggle keyboard access between "all controls" and "text boxes and list only"

  • SF Public Department is running an AIDS risk level assessment, feel free to join up if interested.