Sha256: ebc12ec8c9e6c7e7d20ac0beb163e4af7e435fe9094ebd3499dcbf254647b344

Contents?: true

Size: 641 Bytes

Versions: 1

Compression:

Stored size: 641 Bytes

Contents

require 'spec_helper'

module Logical
  module Naf
    module JobStatuses

      describe Queued do

        context "no conditions" do

          let!(:conditions) { "" }

          it "returns executable query" do
            expect { ActiveRecord::Base.connection.execute(Queued.all(conditions)) }.to_not raise_error
          end

        end

        context "custom conditions" do

          let!(:conditions) { "TEST STRING" }

          it "adds conditions to returned query" do
            sql = Queued.all(conditions)
            expect(sql.include?(conditions)).to be_true
          end

        end

      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
naf-2.1.13 spec/models/logical/naf/job_statuses/queued_spec.rb