This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (alter-var-root | |
| (var clojure.tools.logging/*logger-factory*) | |
| (constantly (clojure.tools.logging.impl/log4j-factory))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {:user | |
| {:search-page-size 100000}} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (ns tektite.client.action | |
| (:require | |
| [tektite.client.util :refer [log]] | |
| [tektite.client.view :as view] | |
| [tektite.client.route :as route] | |
| ) | |
| (:require-macros | |
| [tektite.client.macro :as macro] | |
| )) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (condp re-matches fragment | |
| #"^#$" (home-page) | |
| #"^#designs$" (design-index) | |
| #"^#designs/(.*)$" :>> #(design-edit (get % 1)) | |
| (undefined-route fragment)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| '{:type=>"Product", :client_id=>nil}'.gsub(/:(\w+)\s*=>\s*([^,)}]*)/, '\1: \2') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def escape_single_quotes_for_xpath(string) | |
| if string =~ /'/ | |
| %[concat('] + string.gsub(/'/, %[', "'", ']) + %[')] # horribly, this is how you escape single quotes in XPath. | |
| else | |
| %['#{string}'] | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| beforeEach -> | |
| sinon.FakeXMLHttpRequest.addFilter (httpMethod, url) -> | |
| (httpMethod.match(/get/i) && url.match(/^\/?jasmine/)) != null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module JasmineFixtures | |
| extend ActiveSupport::Concern | |
| # Saves the markup to a fixture file using the given name | |
| def save_fixture(name) | |
| response.should be_success | |
| fixture_path = File.join(Rails.root, '/spec/javascripts/fixtures') | |
| fixture_file = File.join(fixture_path, name) | |
| fixture = case name | |
| when /\.html$/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (defn doall-recur [s] | |
| (if (seq? s) | |
| (doall (map doall-recur | |
| s)) | |
| s)) |