conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Move minimum to 7.0.2 to bring in the latest manageiq-password\n" }, { "from": "human", "value": "# Add gems here, in Gemfile syntax, which are dependencies of the appliance itself rather than a part of the ManageIQ application\ngem \"manageiq-appliance_console\", \...
ruby
chosen
[ { "from": "system", "value": "Modify : pod spec version 1.2.9\n" }, { "from": "human", "value": "\nPod::Spec.new do |s|\n s.name = 'LYCategory'\n s.version = '1.2.8'\n s.summary = 'The categories.'\n\n s.description = <<-DESC\nThe categories for Objective-C...
ruby
chosen
[ { "from": "system", "value": "Add runtime gem dependency on bunny\n" }, { "from": "human", "value": "# coding: utf-8\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'united_workers/version'\n\nGem::Specification.new do |spec|\n spec....
ruby
chosen
[ { "from": "system", "value": "Change dependency to swift 2 version of snapkit\n" }, { "from": "human", "value": "Pod::Spec.new do |s|\n s.name = 'PageMenuController'\n s.version = '0.1.14'\n s.summary = 'An Android like navigation system, with a segmented control...
ruby
chosen
[ { "from": "system", "value": "Revert accidental breakage of moderator/admin checking in moderation\ncontroller\n" }, { "from": "human", "value": "module Forem\n class ModerationController < Forem::ApplicationController\n before_filter :ensure_moderator_or_admin\n\n helper 'forem/posts'\n\...
ruby
chosen
[ { "from": "system", "value": "Check for external auth before login.\n" }, { "from": "human", "value": "module Incline\n ##\n # A simple controller providing the login and logout methods for the application.\n class SessionsController < ApplicationController\n\n # must be anon to login.\n ...
ruby
chosen
[ { "from": "human", "value": "Create our version of Balanced::Verification with a bank account\n" }, { "from": "gpt", "value": "module Neighborly::Balanced\n class Verification\n def self.find(uri)\n new(::Balanced::Verification.find(uri))\n end\n\n def initialize(balanced_verifica...
ruby
chosen
[ { "from": "human", "value": "Add Trouble, and finish lesson 3\n" }, { "from": "gpt", "value": "# Section 3 - Lesson 3 - New Chords Cm, Fm, Gm, Db, Eb, Ab\n# Trouble - Coldplay\nrequire \"#{Dir.home}/ruby/pianoforall/section03/lesson03/half_beat_bounce\"\nuse_synth :piano\nuse_bpm 40\n\nin_thread...
ruby
chosen
[ { "from": "human", "value": "Add Rspec test for the new CatalogItemButton class\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe ApplicationHelper::Button::CatalogItemButton do\n let (:session) { Hash.new }\n before do\n @view_context = setup_view_context_with_sandbox({})\...
ruby
chosen
[ { "from": "human", "value": "Bring spree/api/taxons controller from spree_api as it is needed in OFN admin\n" }, { "from": "gpt", "value": "module Spree\n module Api\n class TaxonsController < Spree::Api::BaseController\n respond_to :json\n\n def index\n if taxonomy\n ...
ruby
chosen
[ { "from": "system", "value": "Fix main menu deface when current_user doesn't exists\n\nContext:\r\n\r\nWhen user visit /admin/password/recover the app throws this error\r\n\r\n`ActionView::Template::Error (undefined method `vendors' for nil:NilClass)`" }, { "from": "human", "value": "Deface::Ove...
ruby
chosen
[ { "from": "system", "value": "Fix servcie life calculator to report the first year that the replacement policy became effective for an asset\n" }, { "from": "human", "value": "#------------------------------------------------------------------------------\n#\n# ServiceLifeCalculator\n#\n# base c...
ruby
chosen
[ { "from": "system", "value": "Create @conversation if the user is signed in\n" }, { "from": "human", "value": "# pages that contain user information but aren't private\nclass PublicPagesController < ApplicationController\n def home\n end\n\n def search\n end\n\n def profile\n profile_use...
ruby
chosen
[ { "from": "system", "value": "Set company for new scm_project.\n" }, { "from": "human", "value": "class ScmProjectsController < ApplicationController\n before_filter :check_access\n\n def new\n @scm_project= ScmProject.new\n end\n\n def create\n @scm_project= ScmProject.new(params[:scm...
ruby
chosen
[ { "from": "system", "value": "Fix add index prometheus metric\n" }, { "from": "human", "value": "# frozen_string_literal: true\n\nclass AddIdentifierToPrometheusMetric < ActiveRecord::Migration\n include Gitlab::Database::MigrationHelpers\n\n DOWNTIME = false\n\n disable_ddl_transaction!\n\n ...
ruby
chosen
[ { "from": "human", "value": "Add an index for a frequent query.\n" }, { "from": "gpt", "value": "class AddNameClassNameIndex < ActiveRecord::Migration\n def self.up\n add_index :text_assets, [:name, :class_name]\n end\n\n def self.down\n remove_index :text_assets, [:name, :class_name]\n...
ruby
chosen
[ { "from": "system", "value": "[CLAide] Load by default the enabled string mixin\n" }, { "from": "human", "value": "# encoding: utf-8\n\n# The mods of interest are {CLAide::ARGV}, {CLAide::Command}, and\n# {CLAide::InformativeError}\n#\nmodule CLAide\n # @return [String]\n #\n # CLAide’s ver...
ruby
chosen
[ { "from": "system", "value": "Add a bitbucket sample URL\n" }, { "from": "human", "value": "class RepositoriesController < ApplicationController\n \n def index\n @repositories = %w{\n git://github.com/theodi/dataset-mod-disposals.git\n git://github.com/datasets/population.git\n ...
ruby
chosen
[ { "from": "system", "value": "Return the authentication token only on login\n" }, { "from": "human", "value": "module Tok\n class SessionsController < BaseController\n # POST /login\n def create\n @model = model_class.authenticate(model_params)\n\n if @model\n render json...
ruby
chosen
[ { "from": "system", "value": "Make mongo service Backup more reliable\n" }, { "from": "human", "value": "module CloudModel\n module Services\n class Mongodb < Base\n field :port, type: Integer, default: 27017\n \n def kind\n :mongodb\n end\n \n def backup...
ruby
chosen
[ { "from": "system", "value": "Revert \"Remove IRC logging of door events\"\n\nThis reverts commit d80d873fb65b6a187f3cafa2c5617f60c135a77e.\n" }, { "from": "human", "value": "module Door::Loggable\n extend ActiveSupport::Concern\n\n included do\n has_one :log_entry, as: :loggable\n befor...
ruby
chosen
[ { "from": "human", "value": "Add indexes on route and stop_area columns of route_segment - used together in stop finding queries.\n" }, { "from": "gpt", "value": "class AddRouteSegmentStopAreaIndices < ActiveRecord::Migration\n def self.up\n add_index :route_segments, [:route_id, :from_stop_...
ruby
chosen
[ { "from": "system", "value": "Fix issue where data_dump `status` where erroneously `inactive`\n" }, { "from": "human", "value": "require \"spec_helper\"\ndescribe Devices::Dump do\n # Resources that I can't easily instantiate via FactoryBot\n SPECIAL = [:points, :sequences, :device]\n ADD...
ruby
chosen
[ { "from": "system", "value": "Use Monitor for recursive locking\n" }, { "from": "human", "value": "require \"mamiya/version\"\nrequire 'thread'\n\nmodule Mamiya\n\n @chdir_mutex = Thread::Mutex.new\n def self.chdir(dir, &block)\n @chdir_mutex.synchronize do\n Dir.chdir(dir, &block)\n ...
ruby
chosen
[ { "from": "system", "value": "Make sure the string has the same length\n\nThe benchmarks tries to expose different comparison times based\non starting / ending with a different character so it shouldn't\ntrigger the shortcut we have that checks length first.\n" }, { "from": "human", "value": "re...
ruby
chosen
[ { "from": "system", "value": "Refactor email code for production heroku\n" }, { "from": "human", "value": "class MainsController < ApplicationController\n\tdef index\n\t\t@albums = Album.all\n\t\t@images = Image.all\n\t\t@contact = Contact.new\n\t\t@projects = Album.order(\"created_at DESC\")\n\...
ruby
chosen
[ { "from": "system", "value": "Add name to email header\n" }, { "from": "human", "value": "class MainsController < ApplicationController\n\tinclude SendGrid\n\t\n\tdef index\n\t\t@albums = Album.all\n\t\t@images = Image.all\n\t\t@contact = Contact.new\n\t\t@projects = Album.order(\"created_at DES...
ruby
chosen
[ { "from": "system", "value": "Put back the switch_to_admin_layout. It was previously misnamed.\n" }, { "from": "human", "value": "class PagesController < ApplicationController\n \n before_filter :authenticate, :except => 'show'\n before_filter :authenticate_with_admin, :except => '...
ruby
chosen
[ { "from": "system", "value": "Fix user controller show route\n" }, { "from": "human", "value": "class UsersController < ApplicationController\n\n def new\n @user = User.new\n end\n\n def create\n @user = User.find_or_create_by(user_params)\n end\n\n def show\n\n end\n\n def edit\n\n...
ruby
chosen
[ { "from": "system", "value": "Make controller action to parse user agent\n" }, { "from": "human", "value": "class UsersController < ApplicationController\n\n\tdef gather\n\t\tputs params.inspect\n\tend\n\nend\n" }, { "from": "gpt", "value": "class UsersController < ApplicationControl...
ruby
chosen
[ { "from": "system", "value": "Make things a little more concise\n" }, { "from": "human", "value": "class UsersController < ApplicationController\n before_filter :authenticate_user!, except: :index\n\n def index\n @users = User.order(created_at: :desc).page(params[:page])\n end\n\n def set...
ruby
chosen
[ { "from": "system", "value": "Revert \"It's someone's birthday :cake:\"\n\nThis reverts commit 5f073d55f6f11465c0be5c5f16c18127b10f265a.\n" }, { "from": "human", "value": "# frozen_string_literal: true\n\nrequire \"test_helper\"\n\nclass GobiertoBudgetConsultations::CsvExporterTest < ActiveSuppo...
ruby
chosen
[ { "from": "system", "value": "Use Ruby 1.9.3's built-in JSON module\n" }, { "from": "human", "value": "require \"json\"\n\nmodule Custodian\n\n # The API class is a Rack-compatible* application that encapsulates\n # Custodian's interface.\n # \n # * http://rack.rubyforge.org/doc/files/SPEC.h...
ruby
chosen
[ { "from": "system", "value": "11992: Add down migration to allow redo\n" }, { "from": "human", "value": "# frozen_string_literal: true\n\nclass RenameOptionSetNameWhereDuplicates < ActiveRecord::Migration[6.1]\n def up\n OptionSet.find_each do |os|\n sets = OptionSet.where(mission_id: o...
ruby
chosen
[ { "from": "system", "value": "Add a simple summary & description\n" }, { "from": "human", "value": "# -*- encoding: utf-8 -*-\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'potatochop/version'\n\nGem::Specification.new do |gem|\n g...
ruby
chosen
[ { "from": "system", "value": "Migrate session cookies to new setup\n\nCurrently sessions set on (www.openfoodnetwork.xxx) are not usable on the bare domain (openfoonetwork.xxx). When transitioning from one to the other, the user's session is completely lost.\n\nThis change means sessions on subdomains (incl...
ruby
chosen
[ { "from": "system", "value": "Remove unnecessary call to cache_key\n" }, { "from": "human", "value": "class Menu < ActiveRecord::Base\n has_many :links, class_name: 'MenuLink'\n\n def self.links_for_menu_cached(menu_name)\n Rails.cache.fetch(Menu.where(name: menu_name).last.cache_key, expir...
ruby
chosen
[ { "from": "system", "value": "Switch to new charset detector shorthand\n" }, { "from": "human", "value": "require '6to5'\nrequire 'sprockets'\nrequire 'sprockets/es6/version'\n\nmodule Sprockets\n class ES6\n def self.instance\n @instance ||= new\n end\n\n def self.call(input)\n ...
ruby
chosen
[ { "from": "system", "value": "Set the app environment using the APPSIGNAL_APP_ENV env var\n" }, { "from": "human", "value": "if defined?(::Rails)\n Appsignal.logger.info(\"Loading Rails (#{Rails.version}) integration\")\n\n module Appsignal\n module Integrations\n class Railtie < ::Rai...
ruby
chosen
[ { "from": "system", "value": "Add forgotten require of Forwardable\n" }, { "from": "human", "value": "require \"benchmark/memory/measurement/metric\"\n\nmodule Benchmark\n module Memory\n # Encapsulate the combined metrics of an action.\n class Measurement\n include Enumerable\n ...
ruby
chosen
[ { "from": "system", "value": "Fix delete button clicker in Capybara tests\n\nAfter ausaccessfed/aaf-lipstick#14 these tests were expecting the old\n(incorrect) 'Confirm Delete' button text which is no longer present.\n\nFixes test failures after upgrading the lipstick library.\n" }, { "from": "human...
ruby
chosen
[ { "from": "system", "value": "Disable Sha512 authlogic crypto provider\n" }, { "from": "human", "value": "class User < ActiveRecord::Base\n\n has_many :assignments, dependent: :destroy #=> many-to-many relation with roles\n has_many :roles, through: :assignments\n\n acts_as_authentic do |c|\n...
ruby
chosen
[ { "from": "system", "value": "Create reader and writer password methods, and add authentication method with some validations\n" }, { "from": "human", "value": "class User < ApplicationRecord\n # Remember to create a migration!\n has_many :rounds\n has_many :guesses, through: :rounds\nend\n" ...
ruby
chosen
[ { "from": "human", "value": "Add Rake task to grant and remove Admin privileges\n" }, { "from": "gpt", "value": "namespace :users do\n namespace :admin do\n def privileges(state)\n raise unless ENV['email']\n u = User.find_by_email!(ENV['email'])\n u.is_admin = state\n u....
ruby
chosen
[ { "from": "system", "value": "Fix example code for FileInput\n\nCloses GH-635\n" }, { "from": "human", "value": "module Formtastic\n module Inputs\n\n # Outputs a simple `<label>` with a `<input type=\"file\">` wrapped in the standard\n # `<li>` wrapper. This is the default input choice f...
ruby
chosen
[ { "from": "system", "value": "Support for embedding YouTube links to particular times\n" }, { "from": "human", "value": "module Onebox\n module Engine\n class YoutubeOnebox\n include Engine\n include StandardEmbed\n\n matches_regexp /^https?:\\/\\/(?:www\\.)?(?:youtube\\.com|y...
ruby
chosen
[ { "from": "system", "value": "Disable rack rewrite for now\n" }, { "from": "human", "value": "# This file is used by Rack-based servers to start the application.\n\nrequire 'rack-rewrite'\n \nDOMAIN = 'aqueousband.net'\n \n# Redirect to the www version of the domain in production\nuse Rack::Rewr...
ruby
chosen
[ { "from": "human", "value": "Add a basic spec for the init subcommand.\n" }, { "from": "gpt", "value": "require File.expand_path('../../../spec_helper', __FILE__)\n\nmodule Pod\n describe Command::Init do\n\n it \"runs with no parameters\" do\n lambda { run_command('init') }.should.not....
ruby
chosen
[ { "from": "human", "value": "Add test for addition fix\n" }, { "from": "gpt", "value": "# frozen_string_literal: true\nrequire \"spec_helper\"\n\ndescribe GraphQL::Schema::Addition do\n it \"handles duplicate types with cycles\" do\n duplicate_types_schema = Class.new(GraphQL::Schema)\n d...
ruby
chosen
[ { "from": "system", "value": "Use override instead of set node attribute\n" }, { "from": "human", "value": "class Chef\n class Recipe\n def add_vim_git_plugin(repository_url)\n node.set[:vim_config][:bundles][:git] = node[:vim_config][:bundles][:git].dup << repository_url unless node[...
ruby
chosen
[ { "from": "system", "value": "Fix code style in Drupal6 detector" }, { "from": "human", "value": "\nmodule Versionator\n module Detector\n # Detects {Drupal 6}[http://drupal.org].\n # This will also detect installed Drupal versions prior to the 6 series.\n # But it will only check for ...
ruby
chosen
[ { "from": "system", "value": "Fix the isolated environment spec on OS X\n\nThe reason this spec was failing is that on OS X the temp directory is\nactually something like this:\n\n/var/folders/bg/8sxn6p0j5kv0j1z__3hwz5nm0000gn/T/\n\nHowever, /var is not an actual folder, but a symlink to /private/var and\nt...
ruby
chosen
[ { "from": "system", "value": "Update to pass new assertion where if no result_id index was found we use a default index value of 0.\n" }, { "from": "human", "value": "module SalesforceBulk\n class QueryResultCollection < Array\n \n attr_reader :client\n attr_reader :batch_id\n attr_...
ruby
chosen
[ { "from": "system", "value": "Resolve $HOME even if VM spits bogus new lines\n\nFixes issue #122\n" }, { "from": "human", "value": "module VagrantPlugins\n module Cachier\n module Cap\n module Linux\n module ComposerPath\n def self.composer_path(machine)\n com...
ruby
chosen
[ { "from": "system", "value": "Use cron_mailto attribute for cron jobs if set" }, { "from": "human", "value": "package 'aide' do\n action :install\nend\n\ntemplate node['aide']['config'] do\n notifies :run, 'bash[generate_database]', :delayed\nend\n\ncron_d 'aide' do\n action :create\n minute...
ruby
chosen
[ { "from": "system", "value": "Refactor to new pattern name.\n" }, { "from": "human", "value": "#\n# Cookbook Name:: mongodb-opsworks\n# Recipe:: default\n#\n# Copyright 2014, Appriss, Inc.\n#\n# All rights reserved - Do Not Redistribute\n#\n\nnode['opsworks']['instance']['layers'].each do |layer...
ruby
chosen
[ { "from": "system", "value": "Set title as a multivalued field\n" }, { "from": "human", "value": "require 'spec_helper'\n\ndescribe 'searching', :type => :feature do\n before { GenericFile.destroy_all }\n let!(:file) { FactoryGirl.create(:public_file, title: \"Toothbrush\") }\n\n context \"as...
ruby
chosen
[ { "from": "system", "value": "Add tests for Resource upload behavior\n" }, { "from": "human", "value": "require 'rails_helper'\n\ndescribe Resource, type: :model do\nend\n" }, { "from": "gpt", "value": "require 'rails_helper'\n\ndescribe Resource, type: :model do\n describe '#upload...
ruby
chosen
[ { "from": "system", "value": "Update updated_at timestamp on eligibility change\n\nThe _adjustment jbuilder view caches based on the adjustment updated_at timestamp. Currently if a promotion is made ineligible by this class and a previous call to api/orders#show has been made, a subsequent calls will send b...
ruby
chosen
[ { "from": "system", "value": "Test that timestamp is set correctly\n" }, { "from": "human", "value": "require 'test_helper'\n\nclass NordeaRenewCertApplicationRequestTest < ActiveSupport::TestCase\n setup do\n @params = nordea_renew_certificate_params\n\n # Convert the keys here since the...
ruby
chosen
[ { "from": "system", "value": "Comment out Marshal badge for time being (clashing with existing Ruby class)\n" }, { "from": "human", "value": "require_relative '../badge'\n\nclass CitizenPatrol < Badge\n def series\n :citizen_patrol\n end\nend\n\nclass Deputy < CitizenPatrol\nend\n\nclass Ma...
ruby
chosen
[ { "from": "human", "value": "Add test file for SitemapHelper\n" }, { "from": "gpt", "value": "require 'test_helper'\n\n#\n# == SitemapHelper Test\n#\nclass SitemapHelperTest < ActionView::TestCase\n include Rails.application.routes.url_helpers\n\n test 'should return correct rss_module content...
ruby
chosen
[ { "from": "system", "value": "Update pod version -> 2.1.0\n" }, { "from": "human", "value": "Pod::Spec.new do |spec|\n spec.name = \"Framezilla\"\n spec.version = \"2.0.0\"\n spec.summary = \"Comfortable syntax for working with frames.\"\n\n spec.homepage ...
ruby
chosen
[ { "from": "system", "value": "Fix rubocop offence for `Style/FrozenStringLiteralComment`\n\n```\n% be rubocop -a\nInspecting 2777 files\n..............................................................................................................................................................................
ruby
chosen
[ { "from": "system", "value": "Use ruby core securerandom as it's removed from latest activesupport\n" }, { "from": "human", "value": "require 'active_support/secure_random'\n\nmodule ActiveMerchant #:nodoc:\n module Utils #:nodoc:\n def generate_unique_id\n SecureRandom.hex(16)\n end...
ruby
chosen
[ { "from": "system", "value": "Prepend `/` to notification links.\n\nNotification links were broken before, giving\nthe reletive href. Now they'll work regardless\nof where the user is at the time of the clicky-\nclick.\n" }, { "from": "human", "value": "class Notify\n def self.everyone(submissi...
ruby
chosen
[ { "from": "system", "value": "Downgrade bundler for Travis CI\n" }, { "from": "human", "value": "# coding: utf-8\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'boost_info/version'\n\nGem::Specification.new do |spec|\n spec.name ...
ruby
chosen
[ { "from": "system", "value": "Add response convenient method to Error Response. Useful for store or logging the error response." }, { "from": "human", "value": "module FootStats\n class ErrorResponse\n include Enumerable\n attr_reader :message\n\n def initialize(message)\n @messag...
ruby
chosen
[ { "from": "system", "value": "Upgrade Reflector.app to v 2.2.0\n" }, { "from": "human", "value": "cask :v1 => 'reflector' do\n version '2.1.0.0'\n sha256 'eda358fec24270e823bd46441ab39e434a616752cd0d5f02456871ee1f870af9'\n\n url \"http://download.airsquirrels.com/Reflector2/Mac/Reflector-#{ve...
ruby
chosen
[ { "from": "system", "value": "Verify wasn't passing the hash back after refactoring with_progress\n" }, { "from": "human", "value": "require_relative 'resource_file'\nrequire_relative 'command_helper'\nrequire_relative 'crc'\n\nmodule FuturoCube\n class VerifyCommand\n include CommandHelper\...
ruby
chosen
[ { "from": "system", "value": "Use configurable strong params list\n\nInstead of hard-coding these, use the global list in the config, minus\nthe subscribable_id, since we don't wish for users to be able to\ncompletely swap out the basis of their subscription.\n" }, { "from": "human", "value": "c...
ruby
chosen
[ { "from": "system", "value": "Fix syntax error for mongoid extension\n" }, { "from": "human", "value": "class Money\n\n # Converts an object of this instance into a database friendly value.\n def mongoize\n {\n :cents => cents,\n :currency_iso => currency.iso_code\n }\n ...
ruby
chosen
[ { "from": "system", "value": "Remove bundle exec from Rubocop check\n" }, { "from": "human", "value": "module Phare\n module Checks\n class RubyRubocop\n attr_reader :status\n\n def initialize\n @command = 'bundle exec rubocop'\n end\n\n def run\n if should_...
ruby
chosen
[ { "from": "human", "value": "Add a spec for RbConfig::CONFIG['UNICODE_VERSION']\n" }, { "from": "gpt", "value": "require_relative '../../spec_helper'\nrequire 'rbconfig'\n\ndescribe \"RbConfig::CONFIG['UNICODE_VERSION']\" do\n ruby_version_is \"\"...\"2.5\" do\n it \"is 9.0.0 for Ruby 2.4\" ...
ruby
chosen
[ { "from": "system", "value": "Update author email address in gemspec file.\n" }, { "from": "human", "value": "# coding: utf-8\n\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\n\nrequire 'messagemedia/version'\n\nGem::Specification.new do |spe...
ruby
chosen
[ { "from": "system", "value": "Add description and summary to gemspec.\n" }, { "from": "human", "value": "# coding: utf-8\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'simple_webmon/version'\n\nGem::Specification.new do |spec|\n sp...
ruby
chosen
[ { "from": "system", "value": "Remove absolute paths from the manifest\n" }, { "from": "human", "value": "if defined?(CompatResource::GEMSPEC)\n raise \"Already loaded ChefCompat from #{CompatResource::GEMSPEC.require_path}/compat_resource/gemspec.rb. Cannot load a second time from #{__FILE__}\"...
ruby
chosen
[ { "from": "system", "value": "Add test-unit as development dependency\n" }, { "from": "human", "value": "# coding: utf-8\n\nGem::Specification.new do |spec|\n spec.name = 'fluent-plugin-gcloud-storage'\n spec.version = '0.1.0'\n spec.authors = ['Gergő Sulymosi']\n spec....
ruby
chosen
[ { "from": "system", "value": "Remove unnecessary integration test case" }, { "from": "human", "value": "# encoding: utf-8\n\nrequire 'spec_helper'\n\ndescribe 'kafka::setup' do\n describe group('kafka') do\n it { should exist }\n end\n\n describe user('kafka') do\n it { should exist }\n...
ruby
chosen
[ { "from": "system", "value": "Introduce parallel destroy for certain providers\n\nThis commit introduces parallel destroy using the batch action class for\nthe destroy command.\n" }, { "from": "human", "value": "module VagrantPlugins\n module CommandDestroy\n class Command < Vagrant.plugin(\...
ruby
chosen
[ { "from": "system", "value": "Update iOS deployment target in podspec\n" }, { "from": "human", "value": "Pod::Spec.new do |s|\n s.name = \"WebKitPlus\"\n s.version = \"0.3.2\"\n s.summary = \"A support library for WKWebView.\"\n\n s.description = <<-DESC\n WebKitPlus is a support ...
ruby
chosen
[ { "from": "system", "value": "Add a warning if dotfile_name is used in V1\n" }, { "from": "human", "value": "require \"vagrant\"\n\nmodule VagrantPlugins\n module Kernel_V1\n class VagrantConfig < Vagrant.plugin(\"1\", :config)\n attr_accessor :dotfile_name\n attr_accessor :host\n\...
ruby
chosen
[ { "from": "human", "value": "Remove path from archived procedures\n" }, { "from": "gpt", "value": "namespace :after_party do\n desc 'Deployment task: remove_path_from_archived_procedures'\n task remove_path_from_archived_procedures: :environment do\n Procedure.archivees.where.not(path: nil)...
ruby
chosen
[ { "from": "system", "value": "Test: Add envrionment variable to skip checking difference\n" }, { "from": "human", "value": "# frozen_string_literal: true\n\nrequire 'minitest/unit'\n\nmodule MiniTest\n module Assertions\n def assert_same_image(expected_image_path, output_image, delta = 0.0)\...
ruby
chosen
[ { "from": "system", "value": "Fix 1.8.x syntax error in spec models\n" }, { "from": "human", "value": "class Jar\n include Mongoid::Document\n identity type: Integer\n has_many :cookies, :class_name => \"Cookie\"\nend\n" }, { "from": "gpt", "value": "class Jar\n include Mongoid::...
ruby
chosen
[ { "from": "system", "value": "Mark the failing (boilerplate) test as pending\n" }, { "from": "human", "value": "require 'spec_helper'\n\ndescribe Roomy do\n it 'has a version number' do\n expect(Roomy::VERSION).not_to be nil\n end\n\n it 'does something useful' do\n expect(false).to eq(...
ruby
chosen
[ { "from": "system", "value": "Add failing test hint for unnecessary H1\n\nAlthough the tests check for the presence of a H1 (#) on the page, the\npresence of a comment in a code block also triggers a failure. This\nisn't easily fixable without a markdown AST.\n\nThis PR adds a hint as to a possible cause, ...
ruby
chosen
[ { "from": "human", "value": "Add feature testing for homepage\n" }, { "from": "gpt", "value": "require 'rails_helper'\n\ndescribe 'feature testing', :type => :feature do\n\n feature 'the home page' do\n\n scenario 'a user can see a register link' do\n visit('/home')\n expect(page)....
ruby
chosen
[ { "from": "system", "value": "Remove already loaded gems by Bundler\n" }, { "from": "human", "value": "# -*- coding: utf-8 -*-\n# Copyright 2014 TIS Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n#...
ruby
chosen
[ { "from": "system", "value": "Remove workaround for UTF-8 issue in Reline\n\nThis has been fixed in commit\nhttps://github.com/ruby/ruby/commit/f8ea2860b0cac1aec79978e6c44168802958e8af\n" }, { "from": "human", "value": "require 'irb'\n\nirbrc_file = IRB.enum_for(:rc_file_generators).first.call(I...
ruby
chosen
[ { "from": "system", "value": "Fix broken PageController tests by using the new active_project factory.\n" }, { "from": "human", "value": "require File.join(File.dirname(__FILE__), '..', 'test_helper')\n\nclass PageControllerTest < ActionController::TestCase\n context 'on GET to :index' do\n ...
ruby
chosen
[ { "from": "human", "value": "Create the unit test of application helper\n" }, { "from": "gpt", "value": "require 'test_helper'\n\nclass ApplicationHelperTest < ActionView::TestCase\n test \"full title helper\" do\n assert_equal full_title, 'Ruby on Rails Tutorial Sample App'\n assert_equa...
ruby
chosen
[ { "from": "system", "value": "Allow to specify the entries directly as an Array instead of reading them from site\n" }, { "from": "human", "value": "module Awestruct\n module Extensions\n class Atomizer\n\n def initialize(entries_name, output_path, opts={})\n @entries_name = entr...
ruby
chosen
[ { "from": "system", "value": "Fix outstanding UselessAssignment lint offenses\n" }, { "from": "human", "value": "class LocationErrorTest < ActiveSupport::TestCase\n context '#initialize' do\n should 'default to default message when no message given' do\n error = LocationError.new(postco...
ruby
chosen
[ { "from": "human", "value": "Add Revisions beta version 2.1\n\nThis commit adds a new cask for the Revisions app. I haven't included\na comment to say where the download link was obtained as it is from a\npublic page on the vendor site: https://www.revisionsapp.com/releases\n" }, { "from": "gpt", ...
ruby
chosen
[ { "from": "human", "value": "Add missing columns to Spree::Konbini\n\nWe're not using these but they are expected on credit cards, so better\nto have them.\n" }, { "from": "gpt", "value": "class AddGatewayProfileIdsToSpreeKonbinis < ActiveRecord::Migration\n def change\n add_column :spree_ko...
ruby
chosen
[ { "from": "system", "value": "Fix the wrapping around this fact.\n\nEmbarrassing this fact was completely broken, but because the spec tests\nfake out the results of the fact it wasn't being picked up.\n" }, { "from": "human", "value": "# Fact: rabbitmq_erlang_cookie\n#\n# Purpose: To determine ...
ruby
chosen
[ { "from": "human", "value": "Add a board view test for the start and end logic of rows\n" }, { "from": "gpt", "value": "require 'spec_helper'\nrequire 'tic_tac_toe/view/board'\n\ndescribe TicTacToe::View::Board do\n\n it 'Properly denotes row starts and ends' do\n bv = TicTacToe::View::Board...
ruby
chosen
[ { "from": "human", "value": "Add specs for state predicate methods\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe Session::State do\n fake(:object)\n fake(:mapper)\n fake(:relation)\n\n describe '#transient?' do\n context 'with transient state' do\n subject { Sess...
ruby
chosen
[ { "from": "system", "value": "Fix to be able to use RubyMotion 3.0\n" }, { "from": "human", "value": "module RumoText\n#\n# TypeHelper\n#\n# https://developer.apple.com/library/mac/documentation/cocoa/conceptual/ObjCRuntimeGuide/Articles/ocrtTypeEncodings.html\n# ref. https://gist.github.com/jsl...
ruby
chosen