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
| Then /response header (.*) should have value of "(*)"/ do |header_name, header_value| | |
| response_headers[header_name].should == header_value | |
| 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
| def options # :nodoc: | |
| @options ||= begin | |
| parser = ::Spec::Runner::OptionParser.new($stderr, $stdout) | |
| parser.order!(ARGV) | |
| parser.options | |
| 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
| class ScheduledChemicalsOrderNotification | |
| include ::DataMapper::Resource | |
| # | |
| # Properties | |
| # | |
| property :scheduled_at, DateTime | |
| property :executed_at, DateTime | |
| property :chemicals_order_id, Integer |
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
| Очередной деплой pump.kg 8 июля. Изменения: | |
| * Лимит размера файна увеличен до 2.5Гб (чтобы @dmsoft наконец скачал образ Федоры :)). Наслаждайтесь :-) | |
| * Таймаут скачивания увеличен до четырёх часов. Посколько ограничения количества потоков сейчас нет, таймаут нужен только для вычленения совсем безнадёжных ссылок. | |
| * Сделано разбиение по страницам (по 50 ссылок). Уж больно быстро накидали ссылок :) | |
| * Повторно постить ссылку теперь можно только если до этого скачивание оканчивалось только ошибкой (вчера вечером кто-то умудрился скачать образ Убунту 13 раз :-)) И ведь скачалось же :)) |
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
| ActionController::Base.param_parsers[Mime::Type.lookup('application/atom+xml')] = Proc.new do |data| | |
| { :entry => Atom::Entry.load_entry(data) } | |
| 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
| class ExtractAnswersTableMigration < ActiveRecord::Migration | |
| def self.up | |
| create_table :answers do |table| | |
| table.string :body | |
| table.integer :question_id | |
| end | |
| answers_strings = Question.all.map(&:answer) | |
| answers_strings.each do |answer_string| | |
| Answer.create! :body => answer_string |
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
| class Configuration | |
| @@value = 1 | |
| def self.value | |
| @@value | |
| 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
| require 'sinatra' | |
| require 'http_router' | |
| require 'http_router/interface/sinatra' | |
| class Application < Sinatra::Base | |
| register HttpRouter::Interface::Sinatra::Extension | |
| params_inspect = lambda { params.inspect + "\n" } | |
| # These routes will work |
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
| Feature: Control access to datasets taking organizations into account | |
| Scenario: User gets a dataset of his own organization | |
| Given there is organization with following properties: | |
| | name | Cucumber, Inc. | | |
| | owner | Cucumber | | |
| | identifier | organization_815 | | |
| When I get /sdata/billingboss/crmErp/organization_815/tradingAccounts | |
| Then response should contain Atom Feed |
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
| # Step 1. Setting up environment | |
| class Government | |
| def power | |
| "belongs to government" | |
| end | |
| end | |
| module People | |
| def power |
OlderNewer