Skip to content

Commit

Permalink
Display the Field Guide with dashboard layout
Browse files Browse the repository at this point in the history
We want the Field Guide to share the same layout as other
admin dashboard screens.
  • Loading branch information
mark-dce committed Aug 31, 2021
1 parent 790b74d commit f5a5745
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/controllers/zizia/metadata_details_controller.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# frozen_string_literal: true
module Zizia
class MetadataDetailsController < ::ApplicationController
with_themed_layout 'dashboard'

def show
@details = MetadataDetails.instance.details(work_attributes:
WorkAttributes.instance)
Expand Down
6 changes: 6 additions & 0 deletions spec/dummy/spec/system/metadata_details_page_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
include Warden::Test::Helpers

RSpec.describe 'Viewing the field guide' do
let(:admin_user) { FactoryBot.create(:admin) }

before do
login_as admin_user
end

it 'renders correctly' do
visit('/importer_documentation/guide')
expect(page).to have_content('title')
Expand Down

0 comments on commit f5a5745

Please sign in to comment.