Magento2 Cert questions dump package 3.

Magento2 Cert questions dump package 3. Try this package to pre-exam cert. It will have you a lot of…

Please enter your email:

1. You have created a module to show manufacturer-list, but in your page need to show Pagination that already ready in your block. Keeping maintainability in mind, where you call echo $block->getPagerHtml(); ?

 
 
 
 

2. How do you instruct Magento to enable a new module?

 
 
 
 

3. You need to add the Google Tag Manager (GTM) to every page. What three steps do you take to accomplish this in MyCompany_MyModule?

 
 
 
 
 

4. You are building an tool that imports products from an ERP. There are 20 columns of additional information that are associated with each product. This extra information must also be associated with an update time to know when to refresh the data. Keeping maintainability in mind, how do you build this into Magento?

 
 
 
 

5. Magento and third-party developers can find it difficult to track and report the dependencies that customized extensions have on other extensions. To address these issues, the Magento system introduces service contracts. What is a Service Contracts – Data interfaces ?

 
 
 
 

6. A custom module is performing an optimized custom query for quote items. The class applies the query customizations on the select object of a quote item collection instance.
public function __construct(
\Magento\Quote\Model\ResourceModel\Quote\Item\Collection $collection) {
$this->collection = $collection;
}
public function fetchData() {
$select = $this->collection->getSelect();
… code modifying $select…
return $this->collection->getData();
}
You are tasked to resolve an issue where the query sometimes does not deliver the expected results. You have debugged the problem and found another class is also using a quote item collection and is loading the collection before the custom module. How do you resolve the issue, keeping maintainability in mind

 
 
 
 

7. You are building a new module to add extra functionality to the Magento application.You want to works with CustomerData the data stored on the client side. Where initialized sections Cart and Directory-data are on the server side via the classes ?

 
 
 
 

8. You are customizing the display of product details page. On this page ur customer need to change the url in which the product category name will be appear as http://mystore.com/women/tops-women/helena-hooded-fleece.html , Keeping ,maintainability in mind ,How to get product url with category?

 
 
 
 

9. You are building CLI that use the console to create a customer account with our custom command as like
php bin/magento customer:user:create –customer-firstname=”Mahin” –customer-lastname=”Rahman” –customer-email=”mahin@example.com” –customer-password=”mahin@123″ –website=”1″
using: protected function configure() { $this->setName(‘customer:user:create’) ->setDescription(‘Create new customer’) ->setDefinition($this->getOptionsList()); } protected function getOptionsList(){ return [ ——————]; } Which below Option are not required in blank? (Choose 2)

 
 
 
 
 
 
 

10. You are making some major adjustments to a core Magento class (ClassA). These adjustments are only necessary when utilized from a specific Magento class (ClassB). You have created MyClass that contains the needed customizations.
Keeping upgradeability in mind, how do you configure di.xml to make the substitution happen?

 
 
 
 

11. You have created a new product type, sample, and need to customize how it renders on the shopping cart page. Keeping maintainability in mind, how do you add a new renderer?

 
 
 
 

12. In a custom module you implement the interface \Magento\Framework\App\Config\DataInterface.
/** Configuration data storage @api */
interface DataInterface {
public function getValue($path);
public function setValue($path, $value);
} What version constraint for magento/framework do you add to your module’s composer.json file?

 
 
 
 

13. As you are scanning folder in the vendor/module-catalog directory, you see a directory that is named Ui.
What is this folder’s purpose?

 
 
 
 

14. What interface should a frontend controllers action implement?

 
 
 
 

15. You have created a module to show manufacturer-list,Your customer need url as www.storeurl/manufacturer which file are mendatory to show correct url?

 
 
 
 
 
 

16. You are updating a module to add extra functionality to the Magento application, Where would Magento look for modules?

 
 
 
 

17. You are reviewing a module to some special functionality to the Magento 2 application, You see directory /Console, What task you think in this directory contain script for this modules?

 
 
 
 
 

18. You need to control access to a custom controller action. How do you tell Magento about this new control option?

 
 
 
 

19. You are implementing a customization of the sales management within a module MyCompany_MySalesProcess. You have created several event observers to add the custom functionality. Each observer is a separate class, but they require some common functionality.
How do you implement the common functionality in the event observers, keeping maintainability and testability in mind?

 
 
 
 

20. You are building CLI that use the console to create a customer account with our custom command, Adding a new command to CLI is based on passing on the argument from the XML level to the class . Dependency Injection comes in handy here. you create the file app/code/Mycompany/Customer/etc/di.xml with the following content: What is the correct in below?

 
 
 
 

21. You are building a new module to add extra functionality to the Magento application. What files are required?

 
 
 
 
 

22. You see this code in etc/adminhtml/routes.xml:


You have placed a controller in Controller/Index/Subscribe.php. If you want to create layout XML instructions for this controller, what would be the layout XML’s filename?

 
 
 
 

23. You are reviewing a module to some special functionality to the Magento 2 application, You see directory /CustomerData, What task you think in this directory contain script for this modules?

 
 
 
 

24. You are trying to determine why a product is not appearing in a category. What table does Magento on the frontend to locate the relationship between a category and its products?

 
 
 
 

25. You are facing a bug, which is supposedly caused by the customization of \Magento\Catalog\Api\ProductRepositoryInterface::save(). To resolve the issue, you decide to find all logic which customizes this method. Which two places do you search for customization declarations? (Choose 2)

 
 
 
 

Leave a Reply