diff --git a/testData/completion/xml/ConstructorArgumentCompletionRegistrar/diXmlMustHaveCompletion/di.xml b/testData/completion/xml/ConstructorArgumentCompletionRegistrar/diXmlMustHaveCompletion/di.xml new file mode 100644 index 000000000..ead25fcc4 --- /dev/null +++ b/testData/completion/xml/ConstructorArgumentCompletionRegistrar/diXmlMustHaveCompletion/di.xml @@ -0,0 +1,14 @@ + + + + + + Foo\Bar\Model\Logger + + + diff --git a/tests/com/magento/idea/magento2plugin/completion/xml/ConstructorArgumentCompletionRegistrarTest.java b/tests/com/magento/idea/magento2plugin/completion/xml/ConstructorArgumentCompletionRegistrarTest.java new file mode 100644 index 000000000..10dded7f7 --- /dev/null +++ b/tests/com/magento/idea/magento2plugin/completion/xml/ConstructorArgumentCompletionRegistrarTest.java @@ -0,0 +1,21 @@ +/** + * Copyright © Magento, Inc. All rights reserved. + * See COPYING.txt for license details. + */ + +package com.magento.idea.magento2plugin.completion.xml; + +import com.magento.idea.magento2plugin.magento.files.ModuleDiXml; + +public class ConstructorArgumentCompletionRegistrarTest extends CompletionXmlFixtureTestCase { + + /** + * Tests for completion of constructor argument in di.xml. + */ + public void testDiXmlMustHaveCompletion() { + final String filePath = this.getFixturePath(ModuleDiXml.FILE_NAME); + myFixture.copyFileToProject(filePath); + + assertFileContainsCompletions(filePath, "logger"); + } +}