Sha256: d869dc942d32457394d3522034138ea7fc7e712d4e496e719e824d57c6102c25

Contents?: true

Size: 935 Bytes

Versions: 1

Compression:

Stored size: 935 Bytes

Contents

# frozen_string_literal: true

require 'rom/files/dataset'
require 'shared/rom/files/media_dataset'

RSpec.describe ROM::Files::Dataset, '#recursive?' do
  include_context 'media dataset'

  subject { dataset.recursive? }

  it { is_expected.to be true }

  context 'after #recursive' do
    let(:dataset) { super().recursive }

    it { is_expected.to be true }
  end

  context 'after #not_recursive' do
    let(:dataset) { super().not_recursive }

    it { is_expected.to be false }
  end

  context 'after manual recursion via #inside' do
    let(:dataset) { super().not_recursive.inside('**') }

    it { is_expected.to be true }
  end

  context 'after manual recursion via #select' do
    let(:dataset) { super().select('**/*.md') }

    it { is_expected.to be true }
  end

  context 'after manual recursion via #select without folder' do
    let(:dataset) { super().select('**') }

    it { is_expected.to be true }
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rom-files-0.2.0 spec/lib/rom/files/dataset/recursive_question_mark_spec.rb