Easter Sale Special 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: exams65

Magento 2 Certified Associate Developer Exam Question and Answers

Magento 2 Certified Associate Developer Exam

Last Update Apr 5, 2024
Total Questions : 103

We are offering FREE Magento-2-Certified-Associate-Developer Magento exam questions. All you do is to just go and sign up. Give your details, prepare Magento-2-Certified-Associate-Developer free exam questions and then go for complete pool of Magento 2 Certified Associate Developer Exam test questions that will help you more.

Magento-2-Certified-Associate-Developer pdf

Magento-2-Certified-Associate-Developer PDF

$35  $99.99
Magento-2-Certified-Associate-Developer Engine

Magento-2-Certified-Associate-Developer Testing Engine

$42  $119.99
Magento-2-Certified-Associate-Developer PDF + Engine

Magento-2-Certified-Associate-Developer PDF + Testing Engine

$56  $159.99
Questions 1

What are two functions of a resource model? (Choose two.)

Options:

A.  

It executes create, retrieve, update and delete actions for an entity

B.  

It loads lists of entity models

C.  

It is made available in the Magento API for the purpose of data manipulation

D.  

It maps an entity to one or more database rows

Discussion 0
Questions 2

You are tasked with ensuring customers who log into the site are authorized. By default, this consists of ensuring the customers email and password match the values in the database. On this project, you need to verify additional data in this process.

Keeping in mind upgradeability, how is this done?

Options:

A.  

Create a before plugin for \Magento\Customer\Api\AccountManagementInterface’s authenticate method

B.  

Create a mutation of a CustomerInterface object to intercept the username and password

C.  

Create an event observer for the user_save_after observer

D.  

Override \Magento\Customer\Controller\AccountController.php

Discussion 0
Questions 3

Which two ways does Magento persist category relationships in the database? (Choose two.)

Options:

A.  

Using slash-separated values in the path field

B.  

in the table catalog_category_index

C.  

in the parent_id field

D.  

Using comma-separated values in the parent-ids field

Discussion 0
Questions 4

You are working on a jewelry store that sells rings. Each ring allows an adjustment in size. The customer specifies finger size in inches and the merchant physically adjusts the stocked ring to the required size.

How is this represented in Magento?

Options:

A.  

Using custom options, with rings as simple products

B.  

Using categories, with each ring size as a separate product

C.  

Using configurable products, with ring size as an attributive value

D.  

Using custom options, with rings as bundle products

Discussion 0
Questions 5

A merchant gives you the module MyCompany_MyModule to install.

How do you identify which REST endpoints are supported by the module?

Options:

A.  

REST endpoints are declared in etc/webapi_rest/di.xml

B.  

Every public method of every interface in the Api folder automatically is exposed as a REST endpoint

C.  

REST endpoints are declared in etc/rest.xml

D.  

REST endpoints are declared in etc/webapi.xml

Discussion 0
Questions 6

A custom module needs to log all calls of \Magento\Customer\Api\AddressRepositoryInterface::save().

Which mechanism do you use?

Options:

A.  

An observer on the customer_address_repository_save event, which is automatically fired for every repository save

B.  

A proxy configured to intercept all calls to any public method and log them

C.  

An extension attribute configured in the extension_attributes.xml

D.  

A plugin declared for the save() method

Discussion 0
Questions 7

You are building a report using complex SQL aggregations to locate the required data.

In what type of class do you put these SQL statements?

Options:

A.  

Resource model

B.  

Repository

C.  

Model

D.  

Helper

Discussion 0
Questions 8

You are adding a new menu item to the admin backend which will link to a custom backend page.

The declaration of the route:

What do you specify as the menu item action attribute value so it links to /admin/mycompany/mymodule/?

Options:

A.  

action=”adminhtml/mycompany/mymodule/”

B.  

action=”admin/mycompany/mymodule/”

C.  

It is not possible without extending the adminhtml route in routes.xml

D.  

action=”mycompany/mymodule/”

Discussion 0
Questions 9

You have created a custom module which must perform an action immediately after an order is placed, but only on the store front of the merchant site. You have selected the checkout_submit_all_after as the target event which the module will observe.

In which file will the event observer be declared?

Options:

A.  

etc/frontend.xml

B.  

etc/events.xml

C.  

etc/config.xml

D.  

etc/frontend/events.xml

Discussion 0
Questions 10

You have been given the task of importing products from an external source. You decide to create a custom module to do this. The class handling the import creates a product for each record, sets the data on it and saves it to the database.

What do you inject into a constructor to represent each product you create?

Options:

A.  

\Magento\Catalog\Model\Product

B.  

\Magento\Catalog\Api\Data\ProductInterfaceFactory

C.  

\Magento\Catalog\Api\Data\ProductInterface

D.  

\Magento\Catalog\Model\ProductBuilder

Discussion 0
Questions 11

The module MyCompany_MyModule provides custom admin interface pages.

Access to these pages should only be granted to specific users.

You add the required configuration to the module’s acl.xml file, but the setting does not seem to work as expected.

How do you visually check if Magento evaluates your ACL resource as expected?

Options:

A.  

Write a plugin for the class \Magento\Framework\Acl\LoaderInterface::populateAcl() and echo out the loaded roles

B.  

Inspect the output of the CLI command bin/magento admin:role:resources – all

C.  

In the browser, open the admin User Roles page. Choose a role and inspect the tree of available resources

D.  

Inspect the response of a GET request to the webapi endpoint http://example.com/rest/V1/acl/resources

Discussion 0
Questions 12

You are setting up a brand new Magento installation for a merchant who is migrating from Magento 1 to Magento 2.

Keeping in mind upgradability and the need to customize, which one do you choose?

Options:

A.  

Create a new Magento instance using composer create-project

B.  

Clone the magento/magento2 GitHub repository

C.  

Run php bin/magento setup:migrate command

D.  

Create a new Magento instance by using the bin/magento install command

Discussion 0
Questions 13

You added a new constructor argument to an existing action controller class.

When you reload the page you get a PHP error that the wrong argument is passed to the class.

How do you fix this?

Options:

A.  

Clean the page cache

B.  

Deploy static content

C.  

Clean the /generated/ folder

D.  

Clean the config cache

Discussion 0
Questions 14

You have added a new attribute origin of the type varchar to the product entity.

Which two calls will filter a product collection with origin set to “California”? (Choose two.)

Options:

A.  

$collection->addFieldToFilter(‘origin’, “California”);

B.  

$collection->addAttributeToSelect(‘origin’, “California”);

C.  

$collection->joinAttribute(‘origin’, ‘catalog_product/origin’, ‘origin’, ‘California”);

D.  

$collection->addAttributeToFilter(‘origin’, “California”);

Discussion 0
Questions 15

Assume that $collection is a new instance of a class that extends

Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection, and $ids is an array of ids.

How do you select a list of records from the database where the record ids are in the $ids list?

Options:

A.  

Option A

B.  

Option B

C.  

Option C

D.  

Option D

Discussion 0