sf test dump dev 1 part 2 Flashcards

1
Q
  1. In which of the following environments can Developers write code? Select all that apply.

Developer edition production org
Enterprise edition production org
Enterprise edition Sandbox org
Professional edition Sandbox org

A

Developer edition production org

Enterprise edition Sandbox org

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q
  1. How can a developer avoid exceeding Governor Limits when using an Apex Trigger? Select all that apply.

By using a helper class that can be invoked from multiple triggers
By using Maps to hold data from query results
By using the Database class to handle DML transactions
By performing DML transactions on lists of Objects

A

By using Maps to hold data from query results

By performing DML transactions on lists of Objects

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q
7. Visualforce components are similar to which type of tag library containing tag namespace prefixes?
 ASP tag library
 JSP tag library
 ASP log file
 DL JSP log file
A

JSP tag library

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q
  1. On a Visualforce page with a custom controller, by using an ID parameter that is passed in the URL, how should a developer retrieve a record? Select all that apply.

Use the constructor method for the controller
Use the $Action.View method in the Visualforce page
Use the tag in the Visualforce page
Create a new PageReference object with the Id

A

Use the constructor method for the controller

Create a new PageReference object with the Id

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
  1. The Review__c object has a lookup relationship with the Job_Application__c object. The Job_Application__c object has a master-detail relationship with the Position__c object. The relationship field names are based on the auto-populated defaults. What is the recommended way to display field data from the related Review__c records on a Visualforce page for a single Position__c record?

Utilize the Standard Controller for Position__c and expression syntax in the Page to display related Review__c data through the Job_Application__c object
Utilize the Standard Controller for Position__c and cross-object Formula Fields on the Job_Application__c object to display Review__c data
Utilize the Standard Controller for Position__c and cross-object Formula Fields on the Review__c object to display Review__c data
Utilize the Standard Controller for Position__c and a Controller Extension to query for Review__c data

A

Utilize the Standard Controller for Position__c and a Controller Extension to query for Review__c data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
  1. Which of these statements are true about the “view state” inspector? Select all that apply.
    Shows components contributing to view state
    Must be enabled on a user profile
    Is displayed only when using
    Is controlled by the Role Hierarchy
A

Shows components contributing to view state
Must be enabled on a user profile
Is displayed only when using

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
15. What type of a programming language is Apex? Select all that apply.
Object-oriented
On-Demand
Water-Fall
Declarative-Specific
A

Object-oriented

On-Demand

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q
  1. When would a developer use a custom controller instead of a controller extension? Select all that apply.
    When a Visualforce page needs to replace the functionality of a standard controller
    When a Visualforce page needs to add new actions to a standard controller
    When a Visualforce page does not reference a single primary object
    When a Visualforce page should not enforce permissions or field-level security
A

When a Visualforce page needs to replace the functionality of a standard controller
When a Visualforce page does not reference a single primary object

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q
  1. A person who does not have “View Encrypted Data” permission will see the field with masked characters. Assuming the field is in the page layout, what happens if he tries to edit the value by clicking on the Edit button?

The field will not appear in the edit layout.
The user will see only masked characters, but can enter a new value and save it.
It will throw an error on changing that field and saving it.
He can see the original value and he can save the record.

A

The user will see only masked characters, but can enter a new value and save it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
  1. A Position is a custom object containing details of each position. A Candidate contains the details of each candidate such as skills. When users view the Position records, they should also be able to see all those candidates who match the skills required for the post. A position record need not have details of candidates and a candidate record can also be kept blank. A position can be applied by multiple candidates, while a candidate can also apply for multiple positions. What can be done to achieve this?

Create a master-child relationship between them
Create a junction object to store both the values
Create a lookup relationship of candidate on position
Create a Visualforce page

A

Create a junction object to store both the values

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
  1. A custom object has an organization-wide default setting of “Private” with Grant Access Using Hierarchies turned off. Which users can select the Sharing button on records for that object?

Only the record owner and a user with the System Administrator profile
The record owner, a user with the System Administrator profile, and a user shared to the record
The record owner, a user shared to the record, any user above the record owner in the role hierarchy, and a user with the System Administrator profile
The record owner, a user above the record owner in the role hierarchy, and a user with the System

A

The record owner, a user with the System Administrator profile, and a user shared to the record

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
  1. Universal Containers tracks reviews as a custom object in a recruiting application. The interview score is tracked on each review record and should have a numerical value, so that hiring managers can calculate scores. The scores should be restricted to integer values 1 through 5 and displayed as a set of radio buttons. How can a developer meet this requirement?
    Create the Interview score field as a picklist, displayed as a radio button on page layout
    Create a formula field that displays the interview score as a set of radio buttons
    Create the interview score field with a data type of radio button
    Create a Visualforce page to display the interview score as a set of radio buttons
A

Create a Visualforce page to display the interview score as a set of radio buttons

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q
  1. Where can custom roll-up summary fields be created using Standard Object relationships? Select all that apply.
    On Opportunity using Opportunity Product records
    On Account using Case records
    On Campaign using Campaign Member records
    On Account using Opportunity records
A

On Opportunity using Opportunity Product records

On Campaign using Campaign Member records
On Account using Opportunity records

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q
  1. A Developer wants to create a custom object to track Customer Invoices. How should Invoices and Accounts be related to ensure that all Invoices are visible to everyone with access to an Account?
    The Account should have a Lookup relationship to the Invoice.
    The Account should have a Master-Detail relationship to the Invoice.
    The Invoice should have a Master-Detail relationship to the Account.
    The Invoice should have a Lookup relationship to the Account.
A

The Invoice should have a Master-Detail relationship to the Account.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
  1. A candidate may apply to multiple jobs at the company Universal Containers by submitting a single application per job posting. Once an application is submitted for a job posting, that application cannot be modified to be resubmitted for another job position. The candidate can apply for a different job posting only by submitting a new application. What can an administrator do to associate an application with each job posting in the schema for the organization?

Create a master-detail relationship in the Application custom object to the Job Postings custom object
Create a master-detail relationship in the Job Postings custom object to the Applications customer object
Create a lookup relationship on both objects to a junction object called Job Posting Applications
Create a lookup relationship in the Applications customer object to the Job Postings custom object

A

Create a master-detail relationship in the Application custom object to the Job Postings custom object

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q
  1. An org has different Apex Classes that provide Account related functionality. After a new validation rule is added to the Account object, many of the test methods fail. What can be done to resolve the failures and reduce the number of code changes needed for future validation rules? Select all that apply.

Create a method that performs a callout for a valid Account record, and call this method from within test methods.
Create a method that creates valid Account records, and call this method from within test methods.
Create a method that queries for valid Account records, and call this method from within test methods.
Create a method that loads valid Account records from a Static Resource, and call this method within test methods.

A

Create a method that creates valid Account records, and call this method from within test methods.
Create a method that loads valid Account records from a Static Resource, and call this method within test methods.

17
Q
  1. A developer is creating an application to track engines and their components. An individual component can be used in different types of engines. What data model should be used to track the data and to prevent orphan records?

Create a junction object to relate many engines to many parts through a master-detail relationship
Create a lookup relationship to represent how each part relates to the parent engine object
Create a master-detail relationship to represent the one-to-many model of engines to parts
Create a junction object to relate many engines to many parts through a lookup relationship

A

Create a junction object to relate many engines to many parts through a master-detail relationship

18
Q
  1. Which of these statements is true for encrypted custom fields? Select all that apply.
    Encrypted fields can be included in Search results.
    Encrypted fields can be included in report results.
    Encrypted fields are not available in filters for list views, reports, and Roll-up summary fields.
    Encrypted fields are not available for validation rules or Apex scripts.
A

Encrypted fields can be included in Search results.
Encrypted fields can be included in report results.
Encrypted fields are not available in filters for list views, reports, and Roll-up summary fields.

19
Q
  1. A developer created an Apex Trigger using the Developer Console and now wants to debug the code. How can the developer accomplish this in the Developer Console?

Select the Override Log Triggers checkbox for the Trigger
Open the Progress tab in the Developer Console
Open the Logs tab in the Developer Console
Add the user name in the Log Inspector

A

Select the Override Log Triggers checkbox for the Trigger

20
Q
  1. Which of the following can be done using the Force.com platform? Select all that apply.

Data-warehousing
Applications with clicks and not code
Applications can be upgraded without loss of customization
Code version control system

A

Applications can be upgraded without loss of customization

Code version control system

21
Q
  1. Which one of the following is not possible to view in the Debug Logs?
Workflow formula evaluation results
Assignment rules
Formula field calculations
Validation rules
Resources used by Apex Script
A

Workflow formula evaluation results
Formula field calculations
Resources used by Apex Script

22
Q
  1. Which of the following will you use for browsing objects and fields in the Force.com IDE? Select all that apply.

Force.com Projects
Schema Explorer
Development Work Area
Debug View

A

Force.com Projects

Schema Explorer

23
Q
  1. A developer creates an Apex class that includes private methods. What can the developer do to ensure that the private methods can be accessed by the test class?
    Add the TestVisible attribute to the Apex class
    Add the SeeAllData attribute to the test methods
    Add the @TestVisible attribute to the Apex methods
    Add the SeeAllData attribute to the test class
A

Add the @TestVisible attribute to the Apex methods

24
Q
59. Where would you find identical Force.com IDs?
 Production and Full Copy Sandbox only
 Production and Dev Sandbox only
 Two developer orgs
 Two Sandbox orgs
A

Production and Full Copy Sandbox only

25
Q

How can a developer refer to, or instantiate, a PageReference in Apex?
Choose 2 answers
A. By using a PageReference with a partial or full URL.
B. By using the Page object and a Visualforce page name.
C. By using the ApexPages.Page() method with a Visualforce page name.
D. By using the PageReference.Page() method with a partial or full URL.

A

A. By using a PageReference with a partial or full URL.

B. By using the Page object and a Visualforce page name.

26
Q

Which requirement needs to be implemented by using standard workflow instead of Process Builder? Choose 2 answers
A. Create activities at multiple intervals.
B. Send an outbound message without Apex code.
C. Copy an account address to its contacts.
D. Submit a contract for approval.

A

B. Send an outbound message without Apex code.

C. Copy an account address to its contacts.

27
Q

A developer has a single custom controller class that works with a Visualforce Wizard to support creating and editing multiple sObjects. The wizard accepts data from user inputs across multiple Visualforce pages and from a parameter on the initial URL Which statement is unnecessary inside the unit test for the custom controller?
A. public ExtendedController(ApexPages.StandardController cntrl) { )
B. ApexPages.currentPage().getParameters() put(input’, ‘TestValue).
C. Test.setCurrentPage(pageRef),
D. String nextPage = controller.save().getUrl();

A

D. String nextPage = controller.save().getUrl();

28
Q

which code represents the Controller in MVC architecture on the Force.com platform Choose 2 answers
A. javaScript that is used to make a menu item display itself.
B. StandardController system methods that are referenced by Visualforce.
C. Custom Apex and JavaScript code that is used to manipulate data.
D. A static resource that contains CSS and images.

A

B. StandardController system methods that are referenced by Visualforce.
C. Custom Apex and JavaScript code that is used to manipulate data.

29
Q

The Review_c object have a lookup relationship to the job_Application_c object.The job_Application_c object has a master detail relationship up to the position_c object.The relationship is based on the auto populated defaults?
What is the recommended way to display field data from the related Review _C records a Visualforce page for a single Position_c record?
A. Utilize the Standard Controller for Position_c and cross -object Formula Fields on the Job_Application c object to display Review_c data.
B. Utilize the Standard Controller for Position_c and a Controller Extension to query for Review _ C data.
c) Utilize the Standard Controller for Position_c and expression syntax in the Page to display related Review_c through me Job_Applicacion_c inject.
D. Utilize the Standard Controller for Position_c and cross -object Formula Fields on the Review_c object to display Review_c data.

A

D. Utilize the Standard Controller for Position_c and cross -object Formula Fields on the Review_c object to display Review_c data.

30
Q

A Developer wants to create a custom object to track Customer Invoices.
How should Invoices and Accounts be related to ensure that all Invoices are visible to everyone with access to Account?
A. The Account should have a Lookup relationship to the Invoice.
B. The Invoice should have a Master -Detail relationship to the Account.
C. The Account should have a Master -Detail relationship to the Invoice.
D. The Invoice should have a Lookup relationship to the Account.

A

B. The Invoice should have a Master -Detail relationship to the Account.