Definition at line 25 of file ilBibtechParserTest.php.
◆ getBibtechContent()
ilBibtechParserTest::getBibtechContent |
( |
| ) |
|
|
protected |
Definition at line 127 of file ilBibtechParserTest.php.
Referenced by testParseBibtechAsArray().
130 author = {Süß, Henrik http://www.testlink.ch}, 131 title = {Last Minute Histologie: [Fit fürs Examen in 2 Tagen!]}, 134 publisher = {Elsevier, Urban & Fischer}, 135 keywords = {Histologie. Lehrbuch}, 136 pages = {XIII, 103 S.}, 137 edition = {1. Aufl.}, 138 ISBN = {978-3-437-43015-2}, 139 ISBN = {3-437-43015-7}, 142 author = {Voll, Markus http://de.wikipedia.org/wiki/a-z}, 143 editor = {Voll, Markus}, 144 title = {Atlas of neuroanatomy for communication science and disorders: based on the work of Michael Schuenke, Erik Schulte, Udo Schumacher}, 145 address = {New York}, 147 publisher = {Thieme}, 148 keywords = {Sprachstörung. Zentralnervensystem. Neuroanatomie. Neuropathologie. Atlas}, 149 pages = {IX, 176 S.}, 150 ISBN = {978-1-60406-649-4},
◆ setUp()
ilBibtechParserTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 29 of file ilBibtechParserTest.php.
References $DIC.
32 $this->dic_backup = is_object($DIC) ? clone
$DIC :
$DIC;
35 $DIC[
'resource_storage'] = $this->createMock(Services::class);
36 $DIC[
'ilDB'] = $this->createMock(ilDBInterface::class);
Customizing of pimple-DIC for ILIAS.
◆ tearDown()
ilBibtechParserTest::tearDown |
( |
| ) |
|
|
protected |
◆ testParseBibtechAsArray()
ilBibtechParserTest::testParseBibtechAsArray |
( |
| ) |
|
Definition at line 45 of file ilBibtechParserTest.php.
References getBibtechContent().
47 $ilBiblEntryFactory = $this->createMock(ilBiblEntryFactoryInterface::class);
48 $ilBiblFieldFactory = $this->createMock(ilBiblFieldFactoryInterface::class);
49 $ilBiblAttributeFactory = $this->createMock(ilBiblAttributeFactoryInterface::class);
53 $ilBiblAttributeFactory
56 $content = $reader->parseContent();
57 $this->assertIsArray($content);
58 $this->assertEquals(2, count($content));
61 $first_item = $content[0];
62 $this->assertEquals(
'book', $first_item[
'entryType']);
63 $this->assertEquals(
'Süß, Henrik http://www.testlink.ch', $first_item[
'author']);
64 $this->assertEquals(
'Last Minute Histologie: [Fit fürs Examen in 2 Tagen!]', $first_item[
'title']);
65 $this->assertEquals(
'München', $first_item[
'address']);
66 $this->assertEquals(
'2012', $first_item[
'year']);
67 $this->assertEquals(
'Elsevier, Urban & Fischer', $first_item[
'publisher']);
68 $this->assertEquals(
'Histologie. Lehrbuch', $first_item[
'keywords']);
69 $this->assertEquals(
'XIII, 103 S.', $first_item[
'pages']);
70 $this->assertEquals(
'1. Aufl.', $first_item[
'edition']);
71 $this->assertEquals(
'3-437-43015-7', $first_item[
'isbn']);
74 $second_item = $content[1];
75 $this->assertEquals(
'journal', $second_item[
'entryType']);
76 $this->assertEquals(
'Voll, Markus http://de.wikipedia.org/wiki/a-z', $second_item[
'author']);
78 'Atlas of neuroanatomy for communication science and disorders: based on the work of Michael Schuenke, Erik Schulte, Udo Schumacher',
81 $this->assertEquals(
'New York', $second_item[
'address']);
82 $this->assertEquals(
'2012', $second_item[
'year']);
83 $this->assertEquals(
'Thieme', $second_item[
'publisher']);
85 'Sprachstörung. Zentralnervensystem. Neuroanatomie. Neuropathologie. Atlas',
86 $second_item[
'keywords']
88 $this->assertEquals(
'IX, 176 S.', $second_item[
'pages']);
89 $this->assertEquals(
'978-1-60406-649-4', $second_item[
'isbn']);
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
◆ $dic_backup
The documentation for this class was generated from the following file: