repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/subquery_join.rb
lib/squeel/nodes/subquery_join.rb
module Squeel module Nodes class SubqueryJoin < Node attr_accessor :subquery, :type, :constraints def initialize(subquery, constraints, type = Squeel::InnerJoin) raise ArgumentError, "subquery(#{subquery}) isn't an Squeel::Nodes::As" unless subquery.is_a?(As) raise Argument...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/key_path.rb
lib/squeel/nodes/key_path.rb
require 'active_support/core_ext/module' module Squeel module Nodes # A node that stores a path of keys (of Symbol, Stub, or Join values) and # an endpoint. Used similarly to a nested hash. class KeyPath < Node include PredicateOperators include Operators # We need some methods to fall...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/stub.rb
lib/squeel/nodes/stub.rb
module Squeel module Nodes # Stub nodes are basically a container for a Symbol that can have handy predicate # methods and operators defined on it since doing so on Symbol will incur the # nerdrage of many. class Stub < Node include PredicateMethods include Operators include Aliasing...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/grouping.rb
lib/squeel/nodes/grouping.rb
module Squeel module Nodes # A node that represents an SQL function call class Grouping < Unary include PredicateMethods include PredicateOperators include Operators include Aliasing include Ordering alias :== :eq alias :'^' :not_eq alias :'!=' :not_eq if resp...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/not.rb
lib/squeel/nodes/not.rb
require 'squeel/nodes/unary' module Squeel module Nodes # A node that represents SQL NOT, and will result in same when visited class Not < Unary end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/as.rb
lib/squeel/nodes/as.rb
require 'squeel/nodes/binary' module Squeel module Nodes # A node representing an SQL alias, which will result in same when visited. class As < Binary alias :expr :left alias :alias :right # @param left The node to be aliased # @param right The alias name def initialize(left, r...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/predicate_operators.rb
lib/squeel/nodes/predicate_operators.rb
module Squeel module Nodes # Operators that act as factories for Or, And, and Not nodes for inclusion # in classes which can be contained inside these nodes. module PredicateOperators # Create a new Or node, with this node as its left-hand node. # @param other The right-hand node for the Or ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/predicate_methods.rb
lib/squeel/nodes/predicate_methods.rb
module Squeel module Nodes # Defines Predicate factories named for each of the Arel predication methods module PredicateMethods (Constants::PREDICATES - [:eq]).each do |method_name| class_eval <<-RUBY def #{method_name}(value = :__undefined__) Nodes::Predicate.new self, :#...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/sifter.rb
lib/squeel/nodes/sifter.rb
module Squeel module Nodes class Sifter < Node include PredicateOperators attr_reader :name, :args def initialize(name, args) @name, @args = name, args end # Implemented for equality testing def hash [name, args].hash end # Compare with other obj...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/join.rb
lib/squeel/nodes/join.rb
require 'active_support/core_ext/module' module Squeel module Nodes # A node representing a joined association class Join < Node undef_method :id if method_defined?(:id) attr_reader :_join delegate :name, :type, :klass, :name=, :type=, :klass=, :to => :_join, :prefix => '' # Create...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/unary.rb
lib/squeel/nodes/unary.rb
module Squeel module Nodes # A node that contains a single expression. class Unary < Node include PredicateOperators # @return The expression contained in the node attr_reader :expr # Create a new Unary node. # @param expr The expression to contain inside the node. def i...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/function.rb
lib/squeel/nodes/function.rb
module Squeel module Nodes # A node that represents an SQL function call class Function < Node include PredicateMethods include PredicateOperators include Operators include Ordering include Aliasing alias :== :eq alias :'^' :not_eq alias :'!=' :not_eq if respo...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/operation.rb
lib/squeel/nodes/operation.rb
require 'squeel/nodes/function' module Squeel module Nodes # An Operation is basically a function with its operands limited, and rearranged, # so Squeel implements it as such. class Operation < Function # Create a new Operation with the given operator and left and right operands # @param lef...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/aliasing.rb
lib/squeel/nodes/aliasing.rb
require 'squeel/nodes/as' module Squeel module Nodes module Aliasing def as(name) As.new(self, Arel.sql(name.to_s)) end end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/nodes/ordering.rb
lib/squeel/nodes/ordering.rb
require 'squeel/nodes/order' module Squeel module Nodes module Ordering # Create an ascending Order node with this Node as its expression # @return [Order] The new Order node def asc Order.new self, 1 end # Create a descending Order node with this Node as its expression ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/core_ext/hash.rb
lib/squeel/core_ext/hash.rb
require 'squeel/nodes/predicate_operators' # Hashes are "acceptable" by PredicateVisitor, so they # can be treated like nodes for the purposes of and/or/not # if you load these extensions. # # @example Load Hash extensions # Squeel.configure do |config| # config.load_core_extensions :hash # end class Hash in...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/core_ext/symbol.rb
lib/squeel/core_ext/symbol.rb
# These extensions to Symbol are loaded optionally, mostly to provide # a small amount of backwards compatibility with MetaWhere. # # @example Load Symbol extensions # Squeel.configure do |config| # config.load_core_extensions :symbol # end class Symbol include Squeel::Nodes::PredicateMethods include Squeel...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/enumeration_visitor.rb
lib/squeel/visitors/enumeration_visitor.rb
require 'active_support/core_ext/module' require 'squeel/nodes' module Squeel module Visitors # The Enumeration visitor class, used to implement Node#each class EnumerationVisitor # Create a new EnumerationVisitor. # # @param [Proc] block The block to execute against each node. def i...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/predicate_visitor.rb
lib/squeel/visitors/predicate_visitor.rb
require 'squeel/visitors/visitor' require 'squeel/visitors/predicate_visitation' module Squeel module Visitors class PredicateVisitor < Visitor include PredicateVisitation private # Expand a belongs_to association that has an AR::Base value. This allows # for queries like: # ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/where_visitor.rb
lib/squeel/visitors/where_visitor.rb
require 'squeel/visitors/predicate_visitor' module Squeel module Visitors class WhereVisitor < PredicateVisitor end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/having_visitor.rb
lib/squeel/visitors/having_visitor.rb
require 'squeel/visitors/predicate_visitor' module Squeel module Visitors class HavingVisitor < PredicateVisitor end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/select_visitor.rb
lib/squeel/visitors/select_visitor.rb
module Squeel module Visitors class SelectVisitor < Visitor include PredicateVisitation end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/preload_visitor.rb
lib/squeel/visitors/preload_visitor.rb
module Squeel module Visitors class PreloadVisitor < Visitor def initialize(_ = nil) # Unused. Just here to provide consistency in method signature # among subclasses of Visitor end def accept(object, parent = nil) visit(object, parent) end def accept!(obje...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/group_visitor.rb
lib/squeel/visitors/group_visitor.rb
module Squeel module Visitors class GroupVisitor < Visitor end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/predicate_visitation.rb
lib/squeel/visitors/predicate_visitation.rb
module Squeel module Visitors module PredicateVisitation EXPAND_BELONGS_TO_METHODS = [:eq, :not_eq] private TRUE_SQL = Arel.sql('1=1').freeze FALSE_SQL = Arel.sql('1=0').freeze # Visit a Squeel sifter by executing its corresponding constraint block # in the parent's class, w...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/from_visitor.rb
lib/squeel/visitors/from_visitor.rb
module Squeel module Visitors class FromVisitor < Visitor alias :visit_String :visit_passthrough end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/order_visitor.rb
lib/squeel/visitors/order_visitor.rb
module Squeel module Visitors class OrderVisitor < Visitor include PredicateVisitation private # Visit an Order node. # # @param [Nodes::Order] o The order node to visit # @param parent The node's parent within the context # @return [Arel::Nodes::Ordering] An ascending ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/visitors/visitor.rb
lib/squeel/visitors/visitor.rb
require 'active_support/core_ext/module' require 'squeel/nodes' module Squeel module Visitors # The Base visitor class, containing the default behavior common to subclasses. class Visitor attr_accessor :context delegate :contextualize, :classify, :find, :traverse, :engine, :arel_visitor, :find!, ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record.rb
lib/squeel/adapters/active_record.rb
case ActiveRecord::VERSION::MAJOR when 3, 4 ActiveRecord::Relation.send :include, Squeel::Nodes::Aliasing require 'squeel/adapters/active_record/base_extensions' adapter_directory = "#{ActiveRecord::VERSION::MAJOR}.#{ActiveRecord::VERSION::MINOR}" Dir[File.expand_path("../active_record/#{adapter_directory}/*.r...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/relation_extensions.rb
lib/squeel/adapters/active_record/relation_extensions.rb
require 'active_record' module Squeel module Adapters module ActiveRecord module RelationExtensions attr_writer :join_dependency private :join_dependency= # Returns a JoinDependency for the current relation. # # We don't need to clear out @join_dependency by overri...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/join_dependency_extensions.rb
lib/squeel/adapters/active_record/join_dependency_extensions.rb
module Squeel module Adapters module ActiveRecord if defined?(::ActiveRecord::Associations::JoinDependency) JoinAssociation = ::ActiveRecord::Associations::JoinDependency::JoinAssociation JoinDependency = ::ActiveRecord::Associations::JoinDependency elsif defined?(::ActiveRecord::Assoc...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/base_extensions.rb
lib/squeel/adapters/active_record/base_extensions.rb
module Squeel module Adapters module ActiveRecord module BaseExtensions def squeel(&block) DSL.eval &block end def sifter(name = nil) if Symbol === name && block_given? singleton_class.send :define_method, "sifter_#{name}", ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/compat.rb
lib/squeel/adapters/active_record/compat.rb
module Arel module Nodes class Grouping < Unary include Arel::Predications end unless Grouping.include?(Arel::Predications) end module Visitors class DepthFirst < Visitor unless method_defined?(:visit_Arel_Nodes_InfixOperation) alias :visit_Arel_Nodes_InfixOperation :binary ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/context.rb
lib/squeel/adapters/active_record/context.rb
require 'squeel/context' module Squeel module Adapters module ActiveRecord JoinPart = if defined?(::ActiveRecord::Associations::JoinDependency::JoinPart) ::ActiveRecord::Associations::JoinDependency::JoinPart elsif defined?(::ActiveRecord::Associations::ClassMethods::JoinDependency::JoinB...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/preloader_extensions.rb
lib/squeel/adapters/active_record/preloader_extensions.rb
module Squeel module Adapters module ActiveRecord module PreloaderExtensions def self.included(base) base.class_eval do alias_method_chain :run, :squeel end end def run_with_squeel unless records.empty? Visitors::PreloadVisitor....
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.1/relation_extensions.rb
lib/squeel/adapters/active_record/4.1/relation_extensions.rb
require 'squeel/adapters/active_record/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions attr_accessor :stashed_join_dependencies private :stashed_join_dependencies, :stashed_join_dependencies= def reset @stashed_join_depend...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.1/reflection_extensions.rb
lib/squeel/adapters/active_record/4.1/reflection_extensions.rb
module Squeel module Adapters module ActiveRecord module ReflectionExtensions def self.included(base) base.extend ClassMethods base.class_eval do class << self alias_method_chain :reflect_on_aggregation, :squeel alias_method_chain :reflect_...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.1/compat.rb
lib/squeel/adapters/active_record/4.1/compat.rb
require 'squeel/adapters/active_record/compat' module ActiveRecord module Associations class AssociationScope def eval_scope(klass, scope, owner) if scope.is_a?(Relation) scope else klass.unscoped.instance_exec(owner, &scope).visited end end end end e...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.1/context.rb
lib/squeel/adapters/active_record/4.1/context.rb
require 'squeel/adapters/active_record/context' module Squeel module Adapters module ActiveRecord class Context < ::Squeel::Context class NoParentFoundError < RuntimeError; end def initialize(object) super @base = object.join_root @engine = @base.base_klass.ar...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.1/preloader_extensions.rb
lib/squeel/adapters/active_record/4.1/preloader_extensions.rb
module Squeel module Adapters module ActiveRecord module PreloaderExtensions def self.included(base) base.class_eval do alias_method_chain :preload, :squeel end end def preload_with_squeel(records, associations, preload_scope = nil) records...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.2/relation_extensions.rb
lib/squeel/adapters/active_record/4.2/relation_extensions.rb
require 'squeel/adapters/active_record/4.1/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions undef_method 'to_sql_with_binding_params' attr_accessor :reverse_order_value private :reverse_order_value, :reverse_order_value= # W...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.2/compat.rb
lib/squeel/adapters/active_record/4.2/compat.rb
require 'squeel/adapters/active_record/4.1/compat'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.2/context.rb
lib/squeel/adapters/active_record/4.2/context.rb
require 'squeel/adapters/active_record/4.1/context'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.2/preloader_extensions.rb
lib/squeel/adapters/active_record/4.2/preloader_extensions.rb
require 'squeel/adapters/active_record/4.1/preloader_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.1/relation_extensions.rb
lib/squeel/adapters/active_record/3.1/relation_extensions.rb
require 'squeel/adapters/active_record/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions def build_arel arel = table.from table build_join_dependency(arel, @joins_values) unless @joins_values.empty? collapse_wheres(arel...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.1/join_dependency_extensions.rb
lib/squeel/adapters/active_record/3.1/join_dependency_extensions.rb
require 'squeel/adapters/active_record/join_dependency_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.1/compat.rb
lib/squeel/adapters/active_record/3.1/compat.rb
require 'squeel/adapters/active_record/compat'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.1/context.rb
lib/squeel/adapters/active_record/3.1/context.rb
require 'squeel/adapters/active_record/context'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.1/preloader_extensions.rb
lib/squeel/adapters/active_record/3.1/preloader_extensions.rb
require 'squeel/adapters/active_record/preloader_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.2/relation_extensions.rb
lib/squeel/adapters/active_record/3.2/relation_extensions.rb
require 'squeel/adapters/active_record/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions def build_arel arel = table.from table build_join_dependency(arel, @joins_values) unless @joins_values.empty? collapse_wheres(arel...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.2/join_dependency_extensions.rb
lib/squeel/adapters/active_record/3.2/join_dependency_extensions.rb
require 'squeel/adapters/active_record/join_dependency_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.2/compat.rb
lib/squeel/adapters/active_record/3.2/compat.rb
require 'squeel/adapters/active_record/compat'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.2/context.rb
lib/squeel/adapters/active_record/3.2/context.rb
require 'squeel/adapters/active_record/context'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.2/preloader_extensions.rb
lib/squeel/adapters/active_record/3.2/preloader_extensions.rb
require 'squeel/adapters/active_record/preloader_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.0/relation_extensions.rb
lib/squeel/adapters/active_record/3.0/relation_extensions.rb
require 'squeel/adapters/active_record/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions # Returns a JoinDependency for the current relation. # # We don't need to clear out @join_dependency by overriding #reset, # because the d...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.0/association_preload_extensions.rb
lib/squeel/adapters/active_record/3.0/association_preload_extensions.rb
module Squeel module Adapters module ActiveRecord module AssociationPreloadExtensions def preload_associations(records, associations, preload_options={}) super(records, Visitors::PreloadVisitor.new.accept(associations), preload_options) end end end end end ActiveReco...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.0/join_dependency_extensions.rb
lib/squeel/adapters/active_record/3.0/join_dependency_extensions.rb
require 'squeel/adapters/active_record/join_dependency_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.0/compat.rb
lib/squeel/adapters/active_record/3.0/compat.rb
module Arel class SelectManager def as other Nodes::TableAlias.new Nodes::SqlLiteral.new(other), Nodes::Grouping.new(@ast) end end class Table alias :table_name :name def [] name if table_exists? columns.find { |column| column.name == name.to_sym } else ::Arel:...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/3.0/context.rb
lib/squeel/adapters/active_record/3.0/context.rb
require 'squeel/adapters/active_record/context' module Squeel module Adapters module ActiveRecord class Context < ::Squeel::Context private def get_arel_visitor Arel::Visitors.visitor_for @engine end end end end end
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.0/relation_extensions.rb
lib/squeel/adapters/active_record/4.0/relation_extensions.rb
require 'squeel/adapters/active_record/relation_extensions' module Squeel module Adapters module ActiveRecord module RelationExtensions # where.not is a pain. It calls the private `build_where` method on its # scope, and since ActiveRecord::Relation already includes the original # ...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.0/join_dependency_extensions.rb
lib/squeel/adapters/active_record/4.0/join_dependency_extensions.rb
require 'squeel/adapters/active_record/join_dependency_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.0/compat.rb
lib/squeel/adapters/active_record/4.0/compat.rb
require 'squeel/adapters/active_record/compat' module ActiveRecord module Associations class AssociationScope # 4.0's eval_scope doesn't play nicely with different bases. Need to do # a similar workaround to the one for AR::Relation#merge, visiting it def eval_scope(klass, scope) if sco...
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.0/context.rb
lib/squeel/adapters/active_record/4.0/context.rb
require 'squeel/adapters/active_record/context'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
activerecord-hackery/squeel
https://github.com/activerecord-hackery/squeel/blob/46072cf81cd81328983bd97e6fdc2e12c2205f17/lib/squeel/adapters/active_record/4.0/preloader_extensions.rb
lib/squeel/adapters/active_record/4.0/preloader_extensions.rb
require 'squeel/adapters/active_record/preloader_extensions'
ruby
MIT
46072cf81cd81328983bd97e6fdc2e12c2205f17
2026-01-04T15:56:01.875204Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/spec_helper.rb
spec/spec_helper.rb
# frozen_string_literal: true # make simplecov optional begin require 'simplecov' require 'simplecov-lcov' # patch simplecov configuration if ! SimpleCov::Configuration.method_defined? :branch_coverage? module SimpleCov module Configuration def branch_coverage? return false ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/libvirt_context.rb
spec/support/libvirt_context.rb
# frozen_string_literal: true require 'fog/libvirt' require 'fog/libvirt/models/compute/server' require 'libvirt' shared_context 'libvirt' do include_context 'unit' let(:libvirt_context) { true } let(:id) { 'dummy-vagrant_dummy' } let(:connection) { double('connecti...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/binding_proc.rb
spec/support/binding_proc.rb
# frozen_string_literal: true ## # A simple extension of the Proc class that supports setting a custom binding # and evaluates everything in the Proc using the new binding. class ProcWithBinding < Proc ## # Set the binding for this instance def apply_binding(bind, *args) @binding = bind instance_exec(*...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/unit_context.rb
spec/support/unit_context.rb
# frozen_string_literal: true require_relative '../spec_helper' shared_context 'unit' do include_context 'vagrant-unit' let(:vagrantfile_providerconfig) { '' } let(:vagrantfile) do <<-EOF Vagrant.configure('2') do |config| config.vm.box = "vagrant-libvirt/test" config.vm.define :test ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/temporary_dir.rb
spec/support/temporary_dir.rb
# frozen_string_literal: true shared_context 'temporary_dir' do around do |example| Dir.mktmpdir("rspec-") do |dir| @temp_dir = dir example.run end end attr_reader :temp_dir end
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/environment_helper.rb
spec/support/environment_helper.rb
# frozen_string_literal: true require 'ostruct' require 'pathname' class EnvironmentHelper attr_writer :domain_name attr_accessor :random_hostname, :name, :default_prefix def [](value) send(value.to_sym) end def cpus 4 end def memory 1024 end %w(cpus cpu_mode loader nvram boot_order...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/libvirt_acceptance_context.rb
spec/support/libvirt_acceptance_context.rb
# frozen_string_literal: true require_relative 'acceptance/context' FALSEY_VALUES = %w[f false no n 0].freeze shared_context 'libvirt_acceptance' do include_context 'acceptance' # The skeleton paths that will be used to configure environments. let(:skeleton_paths) do root = File.expand_path('../acceptance...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/acceptance/configuration.rb
spec/support/acceptance/configuration.rb
# frozen_string_literal: true require 'vagrant-spec/acceptance/configuration' module VagrantPlugins module VagrantLibvirt module Spec module Acceptance class Configuration < Vagrant::Spec::Acceptance::Configuration attr_accessor :clean_on_fail def initialize super ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/acceptance/isolated_environment.rb
spec/support/acceptance/isolated_environment.rb
# frozen_string_literal: true require 'vagrant-spec/acceptance/isolated_environment' require 'vagrant-spec/subprocess' require 'vagrant-spec/which' module VagrantPlugins module VagrantLibvirt module Spec class AcceptanceIsolatedEnvironment < Vagrant::Spec::AcceptanceIsolatedEnvironment # Executes ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/acceptance/context.rb
spec/support/acceptance/context.rb
# frozen_string_literal: true require 'vagrant-spec/acceptance/configuration' require "vagrant-spec/acceptance/rspec/matcher_exit_with" require_relative 'isolated_environment' shared_context "acceptance" do # Setup the environment so that we have an isolated area # to run Vagrant. We do some configuration here a...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/support/matchers/have_file_content.rb
spec/support/matchers/have_file_content.rb
# frozen_string_literal: true require "rspec/expectations/version" # # Taken from https://github.com/cucumber/aruba/blob/main/lib/aruba/matchers/file/have_file_content.rb # with minor modifications # # @!method have_file_content(content) # This matchers checks if <file> has content. `content` can be a string, # re...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/use_qemu_agent_for_connectivity_spec.rb
spec/acceptance/use_qemu_agent_for_connectivity_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'use qemu agent to determine machine private address', acceptance: true do include_context 'libvirt_acceptance' before do environment.skeleton('qemu_agent') end after do assert_execute('vagrant', 'destroy', '--force') end ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/package_domain_spec.rb
spec/acceptance/package_domain_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'package domain', acceptance: true do include_context 'libvirt_acceptance' before(:all) do expect(Vagrant::Util::Which.which('virt-sysprep')).to be_truthy, 'packaging tests requi...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/provider_settings_spec.rb
spec/acceptance/provider_settings_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'provider settings', acceptance: true do include_context 'libvirt_acceptance' after do assert_execute('vagrant', 'destroy', '--force') end context 'with defaults' do before do environment.skeleton('default_settings') ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/snapshots_spec.rb
spec/acceptance/snapshots_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'snapshots', acceptance: true do include_context 'libvirt_acceptance' after(:each) do assert_execute('vagrant', 'destroy', '--force') end before do environment.skeleton('snapshots') end it 'should succeed' do status('T...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/shutdown_halt_spec.rb
spec/acceptance/shutdown_halt_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'shutdown and halt', acceptance: true do include_context 'libvirt_acceptance' before do environment.skeleton('default_settings') end after do assert_execute('vagrant', 'destroy', '--force') end context 'when system accessi...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/additional_storage_spec.rb
spec/acceptance/additional_storage_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'additional storage configured', acceptance: true do include_context 'libvirt_acceptance' before do environment.skeleton('additional_storage') end after do assert_execute('vagrant', 'destroy', '--force') end it 'should suc...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/networking_spec.rb
spec/acceptance/networking_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'package domain', acceptance: true do include_context 'libvirt_acceptance' before(:all) do expect(Vagrant::Util::Which.which('virsh')).to be_truthy, 'networking tests require vir...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/simple_vm_provision_via_shell_spec.rb
spec/acceptance/simple_vm_provision_via_shell_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'simple vm provision via shell', acceptance: true do include_context 'libvirt_acceptance' before do environment.skeleton('simple_vm_provision') end after do assert_execute('vagrant', 'destroy', '--force') end it 'should su...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/acceptance/two_disks_spec.rb
spec/acceptance/two_disks_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' describe 'handle two disk machine', acceptance: true do include_context 'libvirt_acceptance' after do assert_execute('vagrant', 'destroy', '--force') end before do environment.skeleton('two_disks') environment.execute(File.expand_pa...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action_spec.rb
spec/unit/action_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' require 'vagrant/action/runner' require 'vagrant-libvirt/action' describe VagrantPlugins::ProviderLibvirt::Action do subject { described_class } include_context 'libvirt' include_context 'unit' let(:runner) { Vagrant::Action::Runner.new(env)...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
true
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/driver_spec.rb
spec/unit/driver_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' require_relative '../support/binding_proc' require 'fog/libvirt/requests/compute/dhcp_leases' require 'vagrant-libvirt/driver' describe VagrantPlugins::ProviderLibvirt::Driver do include_context 'unit' include_context 'libvirt' subject { describ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/plugin_spec.rb
spec/unit/plugin_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' require 'vagrant-libvirt' require 'vagrant-libvirt/plugin' require 'vagrant-libvirt/action' require 'vagrant-libvirt/action/remove_libvirt_image' describe VagrantPlugins::ProviderLibvirt::Plugin do subject { described_class.new } include_context '...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/config_spec.rb
spec/unit/config_spec.rb
# frozen_string_literal: true require_relative '../spec_helper' require_relative '../support/binding_proc' require 'vagrant-libvirt/config' describe VagrantPlugins::ProviderLibvirt::Config do include_context 'unit' let(:fake_env) { Hash.new } describe '#clock_timer' do it 'should handle all options' do ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
true
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/util/byte_number_spec.rb
spec/unit/util/byte_number_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/util/byte_number' describe ByteNumber do describe '#ByteNumber to Gigrabyte' do it 'should return bigger size' do expect( ByteNumber.new("10737423360").to_GB).to eq(11) expect( ByteNumber.new("737423360").t...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/util/resolvers_spec.rb
spec/unit/util/resolvers_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/util/resolvers' describe VagrantPlugins::ProviderLibvirt::Util::DiskDeviceResolver do subject { described_class.new } def deep_clone_disks(disk_array) new_array = [] disk_array.each do |disk| new_array.push...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/util/network_util_spec.rb
spec/unit/util/network_util_spec.rb
# frozen_string_literal: true require 'rexml/document' require_relative '../../spec_helper' require 'vagrant-libvirt/util/network_util' describe 'VagrantPlugins::ProviderLibvirt::Util::NetworkUtil' do include_context 'libvirt' subject do Class.new do include VagrantPlugins::ProviderLibvirt::Util::Net...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/cap/mount_9p_spec.rb
spec/unit/cap/mount_9p_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt' describe 'VagrantPlugins::ProviderLibvirt::Cap::Mount9P' do include_context 'unit' subject do VagrantPlugins::ProviderLibvirt::Plugin .components .guest_capabilities[:linux] .get(:mount_9p_shared_f...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/cap/synced_folder_virtiofs_spec.rb
spec/unit/cap/synced_folder_virtiofs_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/cap/synced_folder_virtiofs' require 'vagrant-libvirt/util/unindent' describe VagrantPlugins::SyncedFolderVirtioFS::SyncedFolder do include_context 'unit' include_context 'libvirt' subject { described_class.new } des...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/cap/synced_folder_9p_spec.rb
spec/unit/cap/synced_folder_9p_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/cap/synced_folder_9p' require 'vagrant-libvirt/util/unindent' describe VagrantPlugins::SyncedFolder9P::SyncedFolder do include_context 'unit' include_context 'libvirt' subject { described_class.new } describe '#prep...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/package_domain_spec.rb
spec/unit/action/package_domain_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/action/package_domain' describe VagrantPlugins::ProviderLibvirt::Action::PackageDomain do subject { described_class.new(app, env) } include_context 'unit' include_context 'libvirt' include_context 'temporary_dir' ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/clean_machine_folder_spec.rb
spec/unit/action/clean_machine_folder_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/action/clean_machine_folder' describe VagrantPlugins::ProviderLibvirt::Action::CleanMachineFolder do subject { described_class.new(app, env) } include_context 'unit' describe '#call' do before do FileUtils.t...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/create_domain_spec.rb
spec/unit/action/create_domain_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'fog/libvirt/models/compute/volume' require 'vagrant-libvirt/errors' require 'vagrant-libvirt/util/byte_number' require 'vagrant-libvirt/action/create_domain' describe VagrantPlugins::ProviderLibvirt::Action::CreateDomain do subject { desc...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/set_boot_order_spec.rb
spec/unit/action/set_boot_order_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/action/set_boot_order' describe VagrantPlugins::ProviderLibvirt::Action::SetBootOrder do subject { described_class.new(app, env) } include_context 'unit' include_context 'libvirt' #before do # allow(driver).to re...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/resolve_disk_settings_spec.rb
spec/unit/action/resolve_disk_settings_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'fog/libvirt/models/compute/volume' require 'vagrant-libvirt/action/resolve_disk_settings' describe VagrantPlugins::ProviderLibvirt::Action::ResolveDiskSettings do subject { described_class.new(app, env) } include_context 'unit' inclu...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false
vagrant-libvirt/vagrant-libvirt
https://github.com/vagrant-libvirt/vagrant-libvirt/blob/a94ce0d7b6c90129a38435698ca97b364130313d/spec/unit/action/destroy_domain_spec.rb
spec/unit/action/destroy_domain_spec.rb
# frozen_string_literal: true require_relative '../../spec_helper' require 'vagrant-libvirt/action/destroy_domain' describe VagrantPlugins::ProviderLibvirt::Action::DestroyDomain do subject { described_class.new(app, env) } include_context 'unit' include_context 'libvirt' let(:driver) { double('driver') } ...
ruby
MIT
a94ce0d7b6c90129a38435698ca97b364130313d
2026-01-04T15:56:05.820716Z
false