diff stringlengths 65 26.7k | message stringlengths 7 9.92k |
|---|---|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -5,9 +5,7 @@
# Requires supporting ruby files with custom matchers and macros, etc,
# in spec/support/ and its subdirectories.
-Dir[Rails.root.join("spec/support/**/*.rb")].each... | Fix spec helper support file loader
This line would work in a normal app, but the specs are run in the
context of the dummy app, so Rails.root + spec is not going to find
anything.
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -14,3 +14,7 @@ def parse_stanza(xml)
Nokogiri::XML.parse xml
end
+
+def jruby?
+ RUBY_PLATFORM =~ /java/
+end
| Fix checking for JRuby in the specs
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -5,6 +5,15 @@ require 'paranoid'
require 'yaml'
require 'spec'
+
+$enabled = false
+
+ActiveSupport::Notifications.subscribe(/sql/i) do |*args|
+ if $enabled
+ event = Active... | Allow logging of the sql output |
diff --git a/yesand/spec/models/user_spec.rb b/yesand/spec/models/user_spec.rb
index abc1234..def5678 100644
--- a/yesand/spec/models/user_spec.rb
+++ b/yesand/spec/models/user_spec.rb
@@ -17,4 +17,6 @@
it { should validate_uniqueness_of(:username) }
+ it { should allow_value('hello@hello.com').for(:email)}
+
e... | Add email format validation test
|
diff --git a/gems/annoyance/lib/annoyance.rb b/gems/annoyance/lib/annoyance.rb
index abc1234..def5678 100644
--- a/gems/annoyance/lib/annoyance.rb
+++ b/gems/annoyance/lib/annoyance.rb
@@ -1,4 +1,9 @@-require 'annoyance/engine' if defined?(Rails)
+if defined?(Rails)
+ require 'annoyance/engine'
+else
+ require_relati... | Make gem work with and without rails |
diff --git a/spec/unit/puppet/parser/functions/validate_bool_spec.rb b/spec/unit/puppet/parser/functions/validate_bool_spec.rb
index abc1234..def5678 100644
--- a/spec/unit/puppet/parser/functions/validate_bool_spec.rb
+++ b/spec/unit/puppet/parser/functions/validate_bool_spec.rb
@@ -0,0 +1,68 @@+require 'puppet'
+
+# ... | Add spec test for validate_bool function
This is an interesting spec test for module developers.
It illustrates how to cause Puppet to test the function
from the Puppet DSL rather than the Ruby DSL, fully
exercising the system from the perspective of the end
user.
(Note how Puppet[:code] is set, then the scope reset,... |
diff --git a/pivotalcli.gemspec b/pivotalcli.gemspec
index abc1234..def5678 100644
--- a/pivotalcli.gemspec
+++ b/pivotalcli.gemspec
@@ -21,7 +21,7 @@ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]
- spec.add_development_dependency "bundler", "~> 1.13"
+ s... | Update bundler requirement from ~> 1.13 to ~> 2.1
Updates the requirements on [bundler](https://github.com/bundler/bundler) to permit the latest version.
- [Release notes](https://github.com/bundler/bundler/releases)
- [Changelog](https://github.com/rubygems/bundler/blob/master/CHANGELOG.md)
- [Commits](https://github... |
diff --git a/lib/fixbraces.rb b/lib/fixbraces.rb
index abc1234..def5678 100644
--- a/lib/fixbraces.rb
+++ b/lib/fixbraces.rb
@@ -2,7 +2,7 @@ require "tempfile"
module Fixbraces
- def Fixbraces.fixbraces(text)
+ def self.fixbraces(text)
text_changed = false
# Move the opening brace to the same line as t... | Use self.method instead of Fixbraces.method
|
diff --git a/ContainerController.podspec b/ContainerController.podspec
index abc1234..def5678 100644
--- a/ContainerController.podspec
+++ b/ContainerController.podspec
@@ -7,21 +7,21 @@ #
Pod::Spec.new do |s|
- s.name = 'HSContainerController'
+ s.name = 'ContainerController'
s.version ... | Update podspec with new project name
|
diff --git a/lib/dimples/post.rb b/lib/dimples/post.rb
index abc1234..def5678 100644
--- a/lib/dimples/post.rb
+++ b/lib/dimples/post.rb
@@ -25,6 +25,11 @@ @layout = @site.config['layouts']['post']
self.date = Time.mktime(parts[1], parts[2], parts[3])
+
+ @output_directory = File.join(
+ @dat... | Set the output_directory on initialize, and add an inspect method.
|
diff --git a/lib/changeset_patch.rb b/lib/changeset_patch.rb
index abc1234..def5678 100644
--- a/lib/changeset_patch.rb
+++ b/lib/changeset_patch.rb
@@ -12,7 +12,9 @@ def send_diff_emails
logger.info "Sends called+++++++++++++++++++++++++++++++++++" if logger && logger.debug?
# if repository.project.... | Fix error when visit just created repository
|
diff --git a/lib/docomoru/client.rb b/lib/docomoru/client.rb
index abc1234..def5678 100644
--- a/lib/docomoru/client.rb
+++ b/lib/docomoru/client.rb
@@ -1,5 +1,6 @@ require "docomoru/dialogue_methods"
require "docomoru/response"
+require "docomoru/version"
require "active_support/core_ext/object/to_query"
require "f... | Fix missing VERSION constant error
|
diff --git a/lib/needs_csv.rb b/lib/needs_csv.rb
index abc1234..def5678 100644
--- a/lib/needs_csv.rb
+++ b/lib/needs_csv.rb
@@ -4,9 +4,10 @@ class NeedsCsv < CsvRenderer
def to_csv
CSV.generate do |csv|
- csv << ["Id", "Title", "Context", "Tags", "Status", "Audiences", "Updated at"]
+ csv << ["Id", "... | Include extra fields when exporting CSV
|
diff --git a/lib/micromachine.rb b/lib/micromachine.rb
index abc1234..def5678 100644
--- a/lib/micromachine.rb
+++ b/lib/micromachine.rb
@@ -39,9 +39,7 @@ end
def states
- transitions_for.values.map do |transition|
- [transition.keys, transition.values].flatten
- end.flatten.uniq
+ events.map { |e|... | Convert to oneliner suggested by @sci-phi.
|
diff --git a/config/initializers/etsource.rb b/config/initializers/etsource.rb
index abc1234..def5678 100644
--- a/config/initializers/etsource.rb
+++ b/config/initializers/etsource.rb
@@ -12,7 +12,11 @@ ETSOURCE_DIR = APP_CONFIG.fetch(:etsource_working_copy, 'etsource')
ETSOURCE_EXPORT_DIR = ENV['ETSOURCE_DIR'] || AP... | Fix using a relative ETSource directory
Resolves test failures on Semaphore.
|
diff --git a/lib/tent-schemas.rb b/lib/tent-schemas.rb
index abc1234..def5678 100644
--- a/lib/tent-schemas.rb
+++ b/lib/tent-schemas.rb
@@ -8,7 +8,7 @@ end
def schemas
- @schemas ||= schema_files.inject(Hash.new { |h,k| h[k.to_s] }) { |hash,schema|
+ @schemas ||= schema_files.inject(Hash.new { |h,k| h.has... | Fix TentSchemas.[](key): Stop SystemStackError from being raised when key doesn't exist
|
diff --git a/config/schedule.rb b/config/schedule.rb
index abc1234..def5678 100644
--- a/config/schedule.rb
+++ b/config/schedule.rb
@@ -1,5 +1,5 @@ env :MAILTO, nil
-every 3.hours do
- runner "UpdateScheduler.perform_async"
-end
+# every 3.hours do
+# runner "UpdateScheduler.perform_async"
+# end
| Disable auto updates for now
|
diff --git a/vendor/buildr/buildr-osgi-assembler/spec/spec_helper.rb b/vendor/buildr/buildr-osgi-assembler/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/vendor/buildr/buildr-osgi-assembler/spec/spec_helper.rb
+++ b/vendor/buildr/buildr-osgi-assembler/spec/spec_helper.rb
@@ -1,6 +1,6 @@ require 'spec'
-DEFAU... | Make sure helper works with current directory hierarchy
|
diff --git a/app/concerns/couriers/fusionable.rb b/app/concerns/couriers/fusionable.rb
index abc1234..def5678 100644
--- a/app/concerns/couriers/fusionable.rb
+++ b/app/concerns/couriers/fusionable.rb
@@ -35,7 +35,6 @@
table.select("ROWID", "WHERE name='#{photo.key}'").map(&:values).map(&:first).map... | Remove sleep from Fusion Tables
|
diff --git a/app/controllers/media_controller.rb b/app/controllers/media_controller.rb
index abc1234..def5678 100644
--- a/app/controllers/media_controller.rb
+++ b/app/controllers/media_controller.rb
@@ -27,7 +27,7 @@ end
def requested_via_private_vhost?
- request.host == ENV['PRIVATE_ASSET_HOST']
+ reque... | Change private host ENV VAR to be more explicit.
This was driven by a need for clarity in the
puppet config. |
diff --git a/app/controllers/pages_controller.rb b/app/controllers/pages_controller.rb
index abc1234..def5678 100644
--- a/app/controllers/pages_controller.rb
+++ b/app/controllers/pages_controller.rb
@@ -1,7 +1,7 @@ class PagesController < FrontendController
def show
if @page.nil?
- not_found
+ raise... | Fix bug with not_found method calling
|
diff --git a/app/controllers/track_controller.rb b/app/controllers/track_controller.rb
index abc1234..def5678 100644
--- a/app/controllers/track_controller.rb
+++ b/app/controllers/track_controller.rb
@@ -1,6 +1,6 @@ class TrackController < ApplicationController
def index
- @upcoming_events = UpcomingEvents.find_... | Remove hard-coded date from track upcoming events, and default to entire year in advance
|
diff --git a/lib/gutentag/tag_validations.rb b/lib/gutentag/tag_validations.rb
index abc1234..def5678 100644
--- a/lib/gutentag/tag_validations.rb
+++ b/lib/gutentag/tag_validations.rb
@@ -15,7 +15,7 @@ :uniqueness => {:case_sensitive => false}
limit = klass.columns_hash["name"].limit
- klass.validates_... | Use limit.present? to make the condition more explicit
|
diff --git a/app/models/setup/collection_name.rb b/app/models/setup/collection_name.rb
index abc1234..def5678 100644
--- a/app/models/setup/collection_name.rb
+++ b/app/models/setup/collection_name.rb
@@ -5,7 +5,7 @@ included do
field :name, type: String
- validates_format_of :name, with: /\A([a-z]|_)... | Add number option into validates format |
diff --git a/lib/mbsy/util/single_sign_on.rb b/lib/mbsy/util/single_sign_on.rb
index abc1234..def5678 100644
--- a/lib/mbsy/util/single_sign_on.rb
+++ b/lib/mbsy/util/single_sign_on.rb
@@ -12,7 +12,8 @@ raise ArgumentError, "key :email is required" if options[:email].blank?
raise ArgumentError, ":method mu... | Add option for custom domain to single sign on
- Adds `domain` argument to `Mbsy.SingleSignOn.embed_html`
- Falls back to existing `username.getambassador.com` behavior |
diff --git a/lib/perpetuity/attribute_set.rb b/lib/perpetuity/attribute_set.rb
index abc1234..def5678 100644
--- a/lib/perpetuity/attribute_set.rb
+++ b/lib/perpetuity/attribute_set.rb
@@ -2,8 +2,11 @@ class AttributeSet
include Enumerable
- def initialize
+ def initialize *attributes
@attributes ... | Allow AttributeSet to be initialized w/ attributes
|
diff --git a/recipes/rsyslog.rb b/recipes/rsyslog.rb
index abc1234..def5678 100644
--- a/recipes/rsyslog.rb
+++ b/recipes/rsyslog.rb
@@ -0,0 +1,26 @@+#
+# extremly basic loghost setup
+#
+
+if node[:rsyslog].has_key?('server_ip')
+
+ loghost_line = "*.*\t@"
+ loghost_line =+ '@' if node['rsyslog']['protocol'] == 't... | Add recipe for loghost config
|
diff --git a/lib/serverspec/commands/base.rb b/lib/serverspec/commands/base.rb
index abc1234..def5678 100644
--- a/lib/serverspec/commands/base.rb
+++ b/lib/serverspec/commands/base.rb
@@ -57,7 +57,7 @@
def check_cron_entry user, entry
entry_escaped = entry.gsub(/\*/, '\\*')
- "crontab -u #{user... | Change the quote character of argument string of grep, from single to double.
Because single quote doesn't work correctly with escaped single quote in the argument string.
(I don't know why)
|
diff --git a/OKObserver.podspec b/OKObserver.podspec
index abc1234..def5678 100644
--- a/OKObserver.podspec
+++ b/OKObserver.podspec
@@ -1,6 +1,6 @@ Pod::Spec.new do |s|
s.name = "OKObserver"
- s.version = "0.1.0"
+ s.version = "0.0.0"
s.summary = "A lightweight framework ... | Remove version field in podspec
|
diff --git a/adamantium.gemspec b/adamantium.gemspec
index abc1234..def5678 100644
--- a/adamantium.gemspec
+++ b/adamantium.gemspec
@@ -5,15 +5,15 @@ Gem::Specification.new do |gem|
gem.name = 'adamantium'
gem.version = Adamantium::VERSION.dup
- gem.authors = [ 'Dan Kubb', 'Markus Schirp' ]
- ge... | Fix code formatting in gemspec
|
diff --git a/lib/spiderfw/controller/session/flash_hash.rb b/lib/spiderfw/controller/session/flash_hash.rb
index abc1234..def5678 100644
--- a/lib/spiderfw/controller/session/flash_hash.rb
+++ b/lib/spiderfw/controller/session/flash_hash.rb
@@ -13,7 +13,13 @@
def reset
@active = {}
+ ... | Remove variable from flash only when accessed
|
diff --git a/lib/sunspot/redis_index_queue/ordered_heap.rb b/lib/sunspot/redis_index_queue/ordered_heap.rb
index abc1234..def5678 100644
--- a/lib/sunspot/redis_index_queue/ordered_heap.rb
+++ b/lib/sunspot/redis_index_queue/ordered_heap.rb
@@ -20,8 +20,8 @@ def range!(score_begin, score_end, limit = NO_LIMIT)
... | Remove items from redis one by one instead of all in bulk (it's 2.4+ feature)
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -3,6 +3,15 @@
unless defined?(SPEC_ROOT)
SPEC_ROOT = File.expand_path("../", __FILE__)
+end
+
+# The fixtures are UTF-8 encoded.
+# Make sure Ruby uses the proper encoding.
+i... | Make sure Ruby uses the right encoding and doesn't rely on ENV settings. |
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -2,3 +2,12 @@
include SpecInfra::Helper::Exec
+SPEC_TYPE = 'SpecInfra'
+
+module SpecInfra
+ module Commands
+ class Base
+ # dummy class for test
+ end
+ end
+end... | Add dummy commands::base class for testing
|
diff --git a/lib/buoys/link.rb b/lib/buoys/link.rb
index abc1234..def5678 100644
--- a/lib/buoys/link.rb
+++ b/lib/buoys/link.rb
@@ -21,7 +21,7 @@ end
def current?
- !!@current
+ @current
end
def url
| Fix `Avoid the use of double negation (!!).`
|
diff --git a/Casks/duet.rb b/Casks/duet.rb
index abc1234..def5678 100644
--- a/Casks/duet.rb
+++ b/Casks/duet.rb
@@ -1,9 +1,9 @@ cask :v1 => 'duet' do
- version '1.2.5'
- sha256 'd3c178b6b07347fcacc62396706f4f6b9efbbc8d8eb7b0b5f003df0406d59143'
+ version '1.2.9'
+ sha256 'de45914dd00923e372a1d2aa205f4d14e27dd005c22... | Upgrade Duet Display to v1.2.9
Updating Duet Display to version 1.2.9. URL change
reflects the fact that it changes more than just the
version number.
|
diff --git a/test/project_generator_test.rb b/test/project_generator_test.rb
index abc1234..def5678 100644
--- a/test/project_generator_test.rb
+++ b/test/project_generator_test.rb
@@ -13,6 +13,7 @@
def test_generate_project
Ichiban::ProjectGenerator.new(project_dest).generate
+ # Test that each of these ... | Test that project generator creates .gitignore in compiled dir
|
diff --git a/nomadize.gemspec b/nomadize.gemspec
index abc1234..def5678 100644
--- a/nomadize.gemspec
+++ b/nomadize.gemspec
@@ -13,14 +13,6 @@ spec.homepage = "https://github.com/piisalie/nomadize"
spec.license = "MIT"
- # Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
-... | Add version contraint for pg
|
diff --git a/app/controllers/spree/retail/shopify_hooks_controller.rb b/app/controllers/spree/retail/shopify_hooks_controller.rb
index abc1234..def5678 100644
--- a/app/controllers/spree/retail/shopify_hooks_controller.rb
+++ b/app/controllers/spree/retail/shopify_hooks_controller.rb
@@ -0,0 +1,26 @@+module Spree
+ mo... | Add the shopify webhook controller
This will be used for all the webhook controllers that depends on
Shopify. Less code duplication yay!
|
diff --git a/test/servers/sidekiq/worker.rb b/test/servers/sidekiq/worker.rb
index abc1234..def5678 100644
--- a/test/servers/sidekiq/worker.rb
+++ b/test/servers/sidekiq/worker.rb
@@ -14,7 +14,13 @@ ::Instana.logger.warn "Booting background Sidekiq worker..."
Thread.new do
- system("INSTANA_GEM_TEST=true sidekiq #... | Send SIGQUIT to sidekiq when exiting.
|
diff --git a/rspec_rake.gemspec b/rspec_rake.gemspec
index abc1234..def5678 100644
--- a/rspec_rake.gemspec
+++ b/rspec_rake.gemspec
@@ -22,4 +22,5 @@ spec.add_development_dependency "bundler", "~> 1.11"
spec.add_development_dependency "rake", "~> 10.0"
spec.add_development_dependency "rspec", "~> 3.0"
+ spec.... | Add pry to development dependency
|
diff --git a/ochibako-share.gemspec b/ochibako-share.gemspec
index abc1234..def5678 100644
--- a/ochibako-share.gemspec
+++ b/ochibako-share.gemspec
@@ -0,0 +1,14 @@+Gem::Specification.new do |s|
+ s.name = 'ochibako-share'
+ s.version = '0.0.0'
+ s.date = '2015-03-02'
+ s.summary = "A CLI cli... | Create first version of gemspec
|
diff --git a/save_queue.gemspec b/save_queue.gemspec
index abc1234..def5678 100644
--- a/save_queue.gemspec
+++ b/save_queue.gemspec
@@ -21,5 +21,5 @@ # specify any dependencies here; for example:
s.add_development_dependency "rspec", ">= 2.6"
s.add_development_dependency "rake"
- s.add_runtime_dependency "act... | Fix typo in activesupport gem
|
diff --git a/lib/health_monitor/providers/sidekiq.rb b/lib/health_monitor/providers/sidekiq.rb
index abc1234..def5678 100644
--- a/lib/health_monitor/providers/sidekiq.rb
+++ b/lib/health_monitor/providers/sidekiq.rb
@@ -47,7 +47,11 @@ end
def check_redis!
- ::Sidekiq.redis(&:info)
+ if ::S... | Fix deprecation warning when using Sidekiq with redis-namespace
Passing 'info' command to redis as is; administrative commands cannot be
effectively namespaced and should be called on the redis connection
directly; passthrough has been deprecated and will be removed in
redis-namespace 2.0
|
diff --git a/lib/post_publisher/twitter/publisher.rb b/lib/post_publisher/twitter/publisher.rb
index abc1234..def5678 100644
--- a/lib/post_publisher/twitter/publisher.rb
+++ b/lib/post_publisher/twitter/publisher.rb
@@ -6,22 +6,18 @@ end
def publish(args)
- result = @client.update(args.tweet)
-
-... | Raise error when update or retweet failed
|
diff --git a/lib/proxy_rb/drivers/selenium_driver.rb b/lib/proxy_rb/drivers/selenium_driver.rb
index abc1234..def5678 100644
--- a/lib/proxy_rb/drivers/selenium_driver.rb
+++ b/lib/proxy_rb/drivers/selenium_driver.rb
@@ -19,15 +19,12 @@ return
end
- options = {
- proxy: {
- ... | Set the proxy via profile
|
diff --git a/lib/schema/schema/compare/comparison.rb b/lib/schema/schema/compare/comparison.rb
index abc1234..def5678 100644
--- a/lib/schema/schema/compare/comparison.rb
+++ b/lib/schema/schema/compare/comparison.rb
@@ -14,20 +14,20 @@ attr_names ||= control_attributes.keys
entries = attr_names.map ... | Build entry receives both control and compare attribute names
|
diff --git a/capistrano-paratrooper-chef.gemspec b/capistrano-paratrooper-chef.gemspec
index abc1234..def5678 100644
--- a/capistrano-paratrooper-chef.gemspec
+++ b/capistrano-paratrooper-chef.gemspec
@@ -15,5 +15,5 @@ gem.require_paths = ["lib"]
gem.version = Capistrano::Paratrooper::Chef::VERSION
- gem.... | Add version limitation; could not work with capistrano-3.x
|
diff --git a/messaging.gemspec b/messaging.gemspec
index abc1234..def5678 100644
--- a/messaging.gemspec
+++ b/messaging.gemspec
@@ -1,7 +1,7 @@ # -*- encoding: utf-8 -*-
Gem::Specification.new do |s|
s.name = 'evt-messaging'
- s.version = '0.8.0.0'
+ s.version = '0.8.0.1'
s.summary = 'Messaging primitives for... | Package version is increased from 0.8.0.0 to 0.8.0.1
|
diff --git a/messaging.gemspec b/messaging.gemspec
index abc1234..def5678 100644
--- a/messaging.gemspec
+++ b/messaging.gemspec
@@ -1,7 +1,7 @@ # -*- encoding: utf-8 -*-
Gem::Specification.new do |s|
s.name = 'evt-messaging'
- s.version = '0.25.1.0'
+ s.version = '0.26.0.0'
s.summary = 'Common primitives for ... | Package version is increased from 0.25.1.0 to 0.26.0.0
|
diff --git a/messaging.gemspec b/messaging.gemspec
index abc1234..def5678 100644
--- a/messaging.gemspec
+++ b/messaging.gemspec
@@ -1,7 +1,7 @@ # -*- encoding: utf-8 -*-
Gem::Specification.new do |s|
s.name = 'evt-messaging'
- s.version = '0.29.0.10'
+ s.version = '0.29.0.11'
s.summary = 'Common primitives fo... | Package version is increased from 0.29.0.10 to 0.29.0.11
|
diff --git a/db/migrate/20170224113808_remove_specialist_document_editions_with_non_manual_document_type.rb b/db/migrate/20170224113808_remove_specialist_document_editions_with_non_manual_document_type.rb
index abc1234..def5678 100644
--- a/db/migrate/20170224113808_remove_specialist_document_editions_with_non_manual_d... | Remove SpecialistDocumentEditions w/ non-manual document_type
These should've been removed when the related specialist documents were
moved to the newer Specialist Publisher application around the time of
this large commit [1].
I've tested this migration against a dump of the production database
taken on 2017-02-24. ... |
diff --git a/test/run.rb b/test/run.rb
index abc1234..def5678 100644
--- a/test/run.rb
+++ b/test/run.rb
@@ -36,7 +36,7 @@
def self.run
- Test::Unit::UI::Console::TestRunner.run( self )
+ Test::Unit::UI::Console::TestRunner.run( self, output_level: Test::Unit::UI::Console::OutputLevel::VERBOSE )
end
| Use verbose level of Test::Unit
|
diff --git a/spec/chore_spec.rb b/spec/chore_spec.rb
index abc1234..def5678 100644
--- a/spec/chore_spec.rb
+++ b/spec/chore_spec.rb
@@ -21,6 +21,13 @@ expect { Chore.run_hooks_for(:before_perform) }.to_not raise_error
end
+ it 'should pass args to the block if present' do
+ blk = proc {|*args| true }
+ ... | Add specs for the argument handling for global hooks
|
diff --git a/relative_date.rb b/relative_date.rb
index abc1234..def5678 100644
--- a/relative_date.rb
+++ b/relative_date.rb
@@ -1,3 +1,4 @@+# adapted from http://stackoverflow.com/a/195894/391999
module RelativeDate
def to_relative
a = (Time.now-self).to_i
| Add comment with source for RelativeDate
|
diff --git a/LYCategory.podspec b/LYCategory.podspec
index abc1234..def5678 100644
--- a/LYCategory.podspec
+++ b/LYCategory.podspec
@@ -5,7 +5,7 @@ s.summary = 'The categories.'
s.description = <<-DESC
-The categories.
+The categories for Objective-C.
DESC
s.homepage ... | Modify : pod spec description
|
diff --git a/lib/capistrano/tasks/itamae.rake b/lib/capistrano/tasks/itamae.rake
index abc1234..def5678 100644
--- a/lib/capistrano/tasks/itamae.rake
+++ b/lib/capistrano/tasks/itamae.rake
@@ -7,7 +7,7 @@ run_locally do
with target_host: target, ssh_config: ssh_config do
roles.each do |role|
- ... | Use `--ssh-config` instead of `-F`
|
diff --git a/plugins/VMStatus.rb b/plugins/VMStatus.rb
index abc1234..def5678 100644
--- a/plugins/VMStatus.rb
+++ b/plugins/VMStatus.rb
@@ -0,0 +1,79 @@+# -------------------------------------------------------------------------- #
+# Copyright 2011-2012, Research In Motion Limited #
+# ... | Support for custom metrics in availablity policies
|
diff --git a/lib/forem/default_permissions.rb b/lib/forem/default_permissions.rb
index abc1234..def5678 100644
--- a/lib/forem/default_permissions.rb
+++ b/lib/forem/default_permissions.rb
@@ -19,7 +19,11 @@
unless method_defined?(:can_read_forem_forum?)
def can_read_forem_forum?(forum)
- true... | Change default permissions for forem forum
|
diff --git a/lib/girl_friday/error_handler.rb b/lib/girl_friday/error_handler.rb
index abc1234..def5678 100644
--- a/lib/girl_friday/error_handler.rb
+++ b/lib/girl_friday/error_handler.rb
@@ -15,7 +15,7 @@ class ErrorHandler
class Hoptoad
def handle(ex)
- HoptoadNotifier.notify(ex)
+ Hoptoa... | Use notify_or_ignore so Hoptoad can ignore the exception based on local
config
|
diff --git a/lib/libis/workflow/task_group.rb b/lib/libis/workflow/task_group.rb
index abc1234..def5678 100644
--- a/lib/libis/workflow/task_group.rb
+++ b/lib/libis/workflow/task_group.rb
@@ -5,6 +5,9 @@
# noinspection RubyTooManyMethodsInspection
class TaskGroup < Libis::Workflow::Task
+
+ parameter a... | Make task group stop when subtask fails
|
diff --git a/lib/money-rails/mongoid/three.rb b/lib/money-rails/mongoid/three.rb
index abc1234..def5678 100644
--- a/lib/money-rails/mongoid/three.rb
+++ b/lib/money-rails/mongoid/three.rb
@@ -13,9 +13,9 @@ # Get the object as it was stored in the database, and instantiate
# this custom class from it.
def... | Fix error when the keys are not symbolized in mongoid
|
diff --git a/lib/spontaneous/prawn/context.rb b/lib/spontaneous/prawn/context.rb
index abc1234..def5678 100644
--- a/lib/spontaneous/prawn/context.rb
+++ b/lib/spontaneous/prawn/context.rb
@@ -2,7 +2,7 @@ module Context
def asset_path(path, options = {})
asset = _asset_environment.find_assets(path, option... | Return a Pathname rather than a string for assets
|
diff --git a/lib/tasks/default_user_data.rake b/lib/tasks/default_user_data.rake
index abc1234..def5678 100644
--- a/lib/tasks/default_user_data.rake
+++ b/lib/tasks/default_user_data.rake
@@ -3,9 +3,13 @@ task populate: :environment do
Rhinoart::User.create!(name: "Admin",
email: "admin@test.c... | Change default data for install
|
diff --git a/recipes/build.rb b/recipes/build.rb
index abc1234..def5678 100644
--- a/recipes/build.rb
+++ b/recipes/build.rb
@@ -24,8 +24,9 @@ # Set custom packages source folder
if !node['package']['folder'].empty?
cwd "#{node['package']['folder_path']}/#{node['package']['folder']}"
+ else
+ cw... | Fix stupid issue with source folder.
|
diff --git a/test/test_helper.rb b/test/test_helper.rb
index abc1234..def5678 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -4,6 +4,9 @@ ENV['RAILS_ENV'] ||= 'test'
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'
+
+ActiveRecord::Migration.maintain_test_schema!... | Test helper now handles preparing the test DB automatically
rake db:test:prepare is deprected, and is replaced by this line.
|
diff --git a/test/test_helper.rb b/test/test_helper.rb
index abc1234..def5678 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -1,7 +1,7 @@ require 'test/unit'
require 'yaml'
require 'fileutils'
-require File.dirname(__FILE__)+'/../ownet.rb'
+require File.dirname(__FILE__)+'/../lib/ownet.rb'
class Tes... | Fix the require of ownet.
|
diff --git a/test/test_helper.rb b/test/test_helper.rb
index abc1234..def5678 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -6,7 +6,7 @@
Minitest::Reporters.use! Minitest::Reporters::SpecReporter.new
-class Minitest::Spec
+class ActiveSupport::TestCase
include FactoryGirl::Syntax::Methods
be... | Update test helper to better suit rails
|
diff --git a/test/app_helpers.rb b/test/app_helpers.rb
index abc1234..def5678 100644
--- a/test/app_helpers.rb
+++ b/test/app_helpers.rb
@@ -0,0 +1,47 @@+require 'test_helper'
+require 'camping'
+
+Camping.goes :Helpers
+
+module Helpers::Helpers
+ def frontpage
+ R(Index)
+ end
+
+ def current_user
+ User.new... | Add failing test for controllers/models in helpers |
diff --git a/softlayer-report-cli.gemspec b/softlayer-report-cli.gemspec
index abc1234..def5678 100644
--- a/softlayer-report-cli.gemspec
+++ b/softlayer-report-cli.gemspec
@@ -22,8 +22,6 @@ spec.add_dependency 'thor', '~> 0.19.1'
spec.add_dependency 'terminal-table', '~> 1.5.2'
- spec.add_development_dependenc... | Remove excess baggage fro dev deps
|
diff --git a/test/test_helper.rb b/test/test_helper.rb
index abc1234..def5678 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -1,7 +1,4 @@ $LOAD_PATH.unshift File.expand_path('../lib', __FILE__)
-
-require 'minitest/autorun'
-require 'minitest/pride'
unless ENV['CI']
require 'simplecov'
@@ -15,5 +12... | Move simplecov code before minitest is required
|
diff --git a/spec/factories/line_items.rb b/spec/factories/line_items.rb
index abc1234..def5678 100644
--- a/spec/factories/line_items.rb
+++ b/spec/factories/line_items.rb
@@ -6,6 +6,9 @@ price "0.99"
title "Banana"
description "Most delicious banana of all time!"
+ invoice
+ credit_accou... | Add associations to banana line item factory.
|
diff --git a/spec/raven/backtrace_spec.rb b/spec/raven/backtrace_spec.rb
index abc1234..def5678 100644
--- a/spec/raven/backtrace_spec.rb
+++ b/spec/raven/backtrace_spec.rb
@@ -5,7 +5,20 @@ @backtrace = Raven::Backtrace.parse(Thread.current.backtrace)
end
+ it "#lines" do
+ expect(@backtrace.lines.first).t... | Add small amount of extra Backtrace test coverage
|
diff --git a/lib/leaflet-draw-rails.rb b/lib/leaflet-draw-rails.rb
index abc1234..def5678 100644
--- a/lib/leaflet-draw-rails.rb
+++ b/lib/leaflet-draw-rails.rb
@@ -1,4 +1,11 @@ require "leaflet-draw-rails/version"
+require "leaflet-draw-rails/testing"
+
+if defined? RSpec
+ RSpec.configure do |spec|
+ spec.include... | RSpec: Include Testing module, that will contain helpers for tests.
|
diff --git a/uninhibited.gemspec b/uninhibited.gemspec
index abc1234..def5678 100644
--- a/uninhibited.gemspec
+++ b/uninhibited.gemspec
@@ -12,11 +12,12 @@ s.homepage = "http://bernerdschaefer.github.com/uninhibited"
s.summary = ""
s.description = s.summary
+ s.files = Dir.glob("lib/**/*.rb") + %... | Use yard for generating documentation
|
diff --git a/lib/dense.rb b/lib/dense.rb
index abc1234..def5678 100644
--- a/lib/dense.rb
+++ b/lib/dense.rb
@@ -8,6 +8,5 @@
require 'dense/path'
require 'dense/parser'
-require 'dense/errors'
require 'dense/methods'
| Drop useless IndexableError (take 2)
|
diff --git a/Casks/balsamiq-mockups.rb b/Casks/balsamiq-mockups.rb
index abc1234..def5678 100644
--- a/Casks/balsamiq-mockups.rb
+++ b/Casks/balsamiq-mockups.rb
@@ -1,6 +1,6 @@ cask 'balsamiq-mockups' do
- version '3.5.4'
- sha256 'ef2ae819ffee8d7fe1641a260c8fa695caaa8719274b8c733baea5f83f953ae1'
+ version '3.5.5'
+... | Update Balsamiq Mockups to 3.5.5 |
diff --git a/app/models/call.rb b/app/models/call.rb
index abc1234..def5678 100644
--- a/app/models/call.rb
+++ b/app/models/call.rb
@@ -1,4 +1,7 @@ class Call < ActiveRecord::Base
+ belongs_to :player
+ belongs_to :round
+
def bid
return nil if bs?
Bid.new number, face_value
| Create associations in Call model
|
diff --git a/app/models/page.rb b/app/models/page.rb
index abc1234..def5678 100644
--- a/app/models/page.rb
+++ b/app/models/page.rb
@@ -15,8 +15,8 @@
enum status: %i(draft published blocked)
- validates :name, presence: true
-
+ validates :title, presence: true
+ validates :main, uniqueness: true
# trigger... | Update Page to drop other main boolean flags
|
diff --git a/app/models/user.rb b/app/models/user.rb
index abc1234..def5678 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -1,6 +1,10 @@ class User < ActiveRecord::Base
def self.from_omniauth(auth)
- where(provider: auth['provider'], uid: auth['uid']).first || create_from_omniauth(auth)
+ user = w... | Set the token and secret every time in case they've changed
|
diff --git a/gemfiles/travis.rb b/gemfiles/travis.rb
index abc1234..def5678 100644
--- a/gemfiles/travis.rb
+++ b/gemfiles/travis.rb
@@ -1,6 +1,6 @@ source "https://rubygems.org".freeze
-gem "codeclimate-test-reporter".freeze
+gem "codeclimate-test-reporter".freeze if RUBY_VERSION >= "1.9".freeze
gem "json".freeze, ... | Install `codeclimate-test-reporter` only in Ruby 1.9+ versions.
|
diff --git a/gen_idl_history.rb b/gen_idl_history.rb
index abc1234..def5678 100644
--- a/gen_idl_history.rb
+++ b/gen_idl_history.rb
@@ -10,9 +10,11 @@
def read_hist_from_file(file)
res = []
- open(File.expand_path(file)) do |f|
- while l = f.gets
- res << extract_idl_command(l.chomp)
+ if File.exist?(Fi... | Add check if file exists
|
diff --git a/gitmethere.gemspec b/gitmethere.gemspec
index abc1234..def5678 100644
--- a/gitmethere.gemspec
+++ b/gitmethere.gemspec
@@ -20,6 +20,7 @@
spec.add_development_dependency "bundler", "~> 1.6"
spec.add_development_dependency "rake", "~> 10.0"
+ spec.add_development_dependency "rspec", "~> 3.0"
sp... | Add rspec as development dependency
|
diff --git a/lib/PDB/secondary_structure.rb b/lib/PDB/secondary_structure.rb
index abc1234..def5678 100644
--- a/lib/PDB/secondary_structure.rb
+++ b/lib/PDB/secondary_structure.rb
@@ -2,6 +2,13 @@
module PDB
+ # From Stride Documentation
+ # H alpha helix
+ # G 3-10
+ # I PI helix
+ # Extended conformation
+ ... | Add some annotation of secondary structure from STRIDE documentation
|
diff --git a/guard-less.gemspec b/guard-less.gemspec
index abc1234..def5678 100644
--- a/guard-less.gemspec
+++ b/guard-less.gemspec
@@ -16,7 +16,7 @@ # s.rubyforge_project = 'guard-less'
s.add_dependency 'guard', '>= 0.2.2'
- s.add_dependency 'less', '~> 2.1.0'
+ s.add_dependency 'less', '~> 2.3'
... | Update less dependency to current version 2.3.x
|
diff --git a/uberspacify.gemspec b/uberspacify.gemspec
index abc1234..def5678 100644
--- a/uberspacify.gemspec
+++ b/uberspacify.gemspec
@@ -25,7 +25,7 @@ gem.add_dependency 'rack' , '>=1.4.1'
gem.add_dependency 'daemon_controller', '>=1.0.0'
- # dependencies for mysql on Uberspace
+ # dependency... | Revert "needs activerecord-mysql2-adapter as well" ...because it doesn't
This reverts commit 0ed01cd0cf0a4c941c15090efd126f4b0a92cee7.
|
diff --git a/lib/happy-helpers/templates.rb b/lib/happy-helpers/templates.rb
index abc1234..def5678 100644
--- a/lib/happy-helpers/templates.rb
+++ b/lib/happy-helpers/templates.rb
@@ -3,10 +3,12 @@ module HappyHelpers
module Templates
def self.render(name, scope = nil, variables = {}, &block)
- load("view... | Remove hardcoded "views/" view path. |
diff --git a/lib/thinking_sphinx/railtie.rb b/lib/thinking_sphinx/railtie.rb
index abc1234..def5678 100644
--- a/lib/thinking_sphinx/railtie.rb
+++ b/lib/thinking_sphinx/railtie.rb
@@ -1,6 +1,10 @@ # frozen_string_literal: true
class ThinkingSphinx::Railtie < Rails::Railtie
+ config.to_prepare do
+ ThinkingSphin... | Reset configuration when Rails reloads.
I feel like I've hit this problem before, and I thought I'd restructured things in v3 onwards to avoid it, but I guess not. It's reared its head again in #1125 - the cached configuration's indices kept onto their old references to models, whereas models returned from ActiveRecor... |
diff --git a/lib/media_master_client/base.rb b/lib/media_master_client/base.rb
index abc1234..def5678 100644
--- a/lib/media_master_client/base.rb
+++ b/lib/media_master_client/base.rb
@@ -10,22 +10,41 @@ @@app_uid = app_uid
end
+ def self.app_uid
+ @@app_uid
+ end
+
def self.app_secret=(app_secret)
... | Add getter methods for configuration attributes
|
diff --git a/lib/rom/support/class_macros.rb b/lib/rom/support/class_macros.rb
index abc1234..def5678 100644
--- a/lib/rom/support/class_macros.rb
+++ b/lib/rom/support/class_macros.rb
@@ -27,28 +27,23 @@ #
# @api private
def defines(*args)
- mod = Module.new
-
- args.each do |name|
- mod... | Modify ClassMacros to use define_method
Using define_method in favor of module_eval should perform better.
See:
https://tenderlovemaking.com/2013/03/03/dynamic_method_definitions.html
|
diff --git a/app/models/forem/topic.rb b/app/models/forem/topic.rb
index abc1234..def5678 100644
--- a/app/models/forem/topic.rb
+++ b/app/models/forem/topic.rb
@@ -4,7 +4,7 @@
belongs_to :forum
belongs_to :user
- has_many :posts, :dependent => :destroy
+ has_many :posts, :dependent => :destroy, :order... | Order posts by created_at ASC
|
diff --git a/app/services/feed_info.rb b/app/services/feed_info.rb
index abc1234..def5678 100644
--- a/app/services/feed_info.rb
+++ b/app/services/feed_info.rb
@@ -29,13 +29,18 @@ def parse_feed_and_operators
# feed
feed = Feed.from_gtfs(@gtfs, url: @url)
+ feed = Feed.find_by_onestop_id(feed.onestop_id... | Check for existing Feed and Operator
|
diff --git a/app/models/player.rb b/app/models/player.rb
index abc1234..def5678 100644
--- a/app/models/player.rb
+++ b/app/models/player.rb
@@ -17,10 +17,10 @@ end
def pickup!(card)
- actions.create!(effect: Action::PICKUP, card: card)
+ actions.pickup.create!(card: card)
end
def play!(card)
- ... | Refactor action creation method to use play and pickup scopes
|
diff --git a/app/contexts/events_filtering.rb b/app/contexts/events_filtering.rb
index abc1234..def5678 100644
--- a/app/contexts/events_filtering.rb
+++ b/app/contexts/events_filtering.rb
@@ -1,5 +1,5 @@ require 'role_playing'
-require 'refinements/method_chain'
+require 'core_ext/then_if'
require 'paginated_datase... | Use then_if in events filtering
|
diff --git a/app/helpers/topologies_helper.rb b/app/helpers/topologies_helper.rb
index abc1234..def5678 100644
--- a/app/helpers/topologies_helper.rb
+++ b/app/helpers/topologies_helper.rb
@@ -3,7 +3,7 @@ if topology.new_record? && topology.graph.blank?
TopologyTemplate::DEFAULT_GRAPH
elsif topology.gra... | Convert topology graph as string to json
Fixes: #1552
|
diff --git a/app/helpers/transcribe_helper.rb b/app/helpers/transcribe_helper.rb
index abc1234..def5678 100644
--- a/app/helpers/transcribe_helper.rb
+++ b/app/helpers/transcribe_helper.rb
@@ -12,7 +12,7 @@ pivot, end_index = match.offset(0)
# Generate a list of \n indexes
- linebreaks = [0]
+ ... | Fix for 1-line documents (no \n)
|
diff --git a/spec/facade_spec.rb b/spec/facade_spec.rb
index abc1234..def5678 100644
--- a/spec/facade_spec.rb
+++ b/spec/facade_spec.rb
@@ -0,0 +1,57 @@+require 'fileutils'
+require 'spec_helper'
+require 'tmpdir'
+
+module Vim
+ module Flavor
+ describe Facade do
+ describe '#create_vim_script_for_bootstrap'... | Add a spec for bootstrap script
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -8,6 +8,8 @@ require 'rubygems'
require 'bundler/setup'
+MINIMUM_COVERAGE = 57
+
if ENV['COVERAGE']
require 'simplecov'
require 'simplecov-rcov'
@@ -16,6 +18,14 @@ ad... | Add coverage requirements (57% is current coverage)
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -2,7 +2,8 @@ require 'simplecov'
if ENV['COVERAGE']
SimpleCov.start do
- add_filter "/spec/"
+ add_filter '/spec/'
+ add_filter '/vendor/'
end
end
... | Add simplecov filter for vendor directory
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index abc1234..def5678 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -26,5 +26,5 @@
RSpec.configure do |config|
config.platform = 'centos'
- config.version = '6.5'
+ config.version = '6.6'
end
| Set centos 6.6 as the os version
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.