This gist contains all you need to setup capybara for selenium with headless chrome.
- Add these gems to the Gemfile under test group
gem 'capybara'
gem 'chromedriver-helper
gem 'selenium-webdriver'
smartctl 6.6 2017-11-05 r4594 [Darwin 17.4.0 x86_64] (local build) | |
Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org | |
=== START OF INFORMATION SECTION === | |
Model Family: Hitachi Ultrastar 7K3000 | |
Device Model: Hitachi HUA723020ALA641 | |
Serial Number: YFG86ELA | |
LU WWN Device Id: 5 000cca 223c3bb23 | |
Firmware Version: MK7OA840 | |
User Capacity: 2,000,398,934,016 bytes [2.00 TB] |
tap "caskroom/cask" | |
cask "google-chrome" | |
cask "firefox" | |
brew "chromedriver" | |
brew "geckodriver" |
import React from 'react' | |
import { observer } from 'mobx-react' | |
function ArtistList({ uiState: { artistData } }) { | |
const { data } = artistData; | |
if ( !data || !data.artists || !data.artists.length ) { | |
return <div>No artists bruh.</div> | |
} | |
const { artists } = data | |
return ( |
def download_zip(image_list) | |
unless image_list.blank? | |
file_name = 'pictures.zip' | |
stringio = Zip::ZipOutputStream::write_buffer do |z| | |
image_list.each do |img| | |
title = img.title | |
title += '.jpg' unless title.end_with?('.jpg') | |
z.put_next_entry(title) |
require 'csv' | |
module DownloadService | |
OPEN_MODE = "w+:UTF-16LE:UTF-8" | |
BOM = "\xEF\xBB\xBF" #Byte Order Mark | |
def student_list | |
File.open("#{file_name}.tsv", OPEN_MODE) do |f| | |
csv_file = CSV.generate({:col_sep => "\t"}) do |csv| | |
# header row |
(ns roman-numerals.core-test | |
(:require [clojure.test :refer :all])) | |
(def mapping { | |
0 "" | |
1 "I" | |
4 "IV" | |
5 "V" | |
9 "IX" | |
10 "X" |
/** | |
* Ref $elector Mixin | |
*/ | |
export default { | |
$(ref) { | |
return this.refs[ref].getDOMNode() | |
} | |
} |