Sha256: 18c0a2453c0ce818333cb7a9822a47f95fb7b92ce55101d3c9ecf9b30e800637

Contents?: true

Size: 779 Bytes

Versions: 12

Compression:

Stored size: 779 Bytes

Contents

require 'rails_helper'

RSpec.feature 'Document Attributes', type: :feature do
  describe 'published', js: true do
    context 'when published is true' do
      it 'will list the documentation' do
        create_json = {
          published: true,
          name: 'Create Currency'
        }
        DocumentationBuilder.create(create_json)

        visit '/apidoco'
        expect(page).to have_text(create_json[:name])
      end
    end

    context 'when published is false' do
      it 'will list the documentation' do
        create_json = {
          published: false,
          name: 'Create Currency'
        }
        DocumentationBuilder.create(create_json)

        visit '/apidoco'
        expect(page).to have_no_text(create_json[:name])
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
apidoco-1.6.4 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.6.3 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.6.2 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.6.1 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.6.0 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.6 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.5 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.4 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.3 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.2 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.1 spec/features/apidoco/documentation_attributes/published_spec.rb
apidoco-1.5.0 spec/features/apidoco/documentation_attributes/published_spec.rb