Skip to content
Snippets Groups Projects
Commit 59eb87f6 authored by Lucas Gabriel Lima's avatar Lucas Gabriel Lima
Browse files

add test to institution importer

parent 9e91b25e
No related branches found
No related tags found
No related merge requests found
......@@ -44,4 +44,12 @@ institution_lo:
name: 'Institution Object 1'
description: 'Testing'
author: 'Mauricio'
publisher: ufpr (Institution)
\ No newline at end of file
publisher: ufpr (Institution)
lo_complete:
name: 'Institution Object 1'
description: 'Testing'
author: 'Mauricio'
id_dspace: '1'
object_type: image
language: portuguese
require 'test_helper'
class InstitutionImporterTest < ActiveSupport::TestCase
test 'importing learning object with metadata publisher = nil' do
importer = InstitutionImporter.new()
lo = learning_objects(:lo_complete)
importer.items = [lo]
importer.import
assert_not_nil Institution.find_by_name(lo.publisher.name)
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment