We use cookies to personalize your experience. If you continue browsing you will be accepting its use. More information.
option

CRI 3

INFO STADISTICS RECORDS
TAKE THE TEST
Title of test:
CRI 3

Description:
Teste 123

Author:
Cristianoma
(Other tests from this author)

Creation Date:
22/01/2020

Category:
Others
Share the Test:
Facebook
Twitter
Whatsapp
TAKE THE TEST
Last comments
No comments about this test.
Content:
How should a developer avoid hitting the governor limits in test methods? Use @TestVisible on methods that create records. Use Test.loadData() to load data from a static resource. Use @IsTest (SeeAllData=true) to use existing data. Use Test.startTest() to reset governor limits.
A developer is asked to create a PDF quote document formatted using the company’s branding guidelines, and automatically save it to the Opportunity record. Which two ways should a developer create this functionality? (Choose two.) Install an application from the AppExchange to generate documents. Create a Visualforce page with custom styling. Create an email template and use it in Process Builder. Create a visual flow that implements the company’s formatting.
Which tool allows a developer to send requests to the Salesforce REST APIs and view the responses? REST resource path URL Workbench REST Explorer Developer Console REST tab Force.com IDE REST Explorer tab.
A developer encounters APEX heap limit errors in a trigger. Which two methods should the developer use to avoid this error? (Choose two.) Use the transient keyword when declaring variables. Query and store fields from the related object in a collection when updating related objects. Remove or set collections to null after use. Use SOQL for loops instead of assigning large queries results to a single collection and looping through the collection.
Universal Containers wants Opportunities to be locked from editing when reaching the Closed/Won stage. Which two strategies should a developer use to accomplish this? (Choose two.) A. Use a Visual Workflow. B. Use a validation rule. C. Use the Process Automation Settings. D. Use a Trigger.
A developer writers the following code: List<Account> acc = [SELECT id FROM Account LIMIT 10]; Delete acc; Database.emptyRecycleBin(acc); System.Debug( Limits.getDMLStatements() + ',' + Limits.getLimitDMLStatements() ); 1, 100 1, 150 2, 150 2, 200.
What is the result of the debug statements in testMethod3 when you create test data using testSetup in below code? @isTest private class CreateAndExecuteTest { @testSetup static void setup() { // Create 2 test accounts List<Account> testAccts = new List<Account>(); for(Integer i=0; 1<2; i++) { testAccts.add(new Account (Name = 'MyTestAccount' +i, Phone='333-878')); } insert testAccts; } @isTest static void testMethod1() { Account acc = [SELECT id, Phone FROM Account WHERE Name='MyTestAccount0' LIMIT 1]; acc.Phone = '888-1515'; update acc; Account acc2 = [SELECT id, Phone FROM Account WHERE Name='MyTestAccount1' LIMIT 1]; acc.Phone = '999-1515'; update acc2; } @isTest static void testMethod2() { Account acc [SELECT Id, Phone FROM Account WHERE Name= 'MyTestAccount1' LIMIT1]; acc.Phone = '888-2525'; update acc; } @isTest static void testMethod3() { Account acc0 = [SELECT Id, Phone FROM Account WHERE Name= 'MyTestAccount0' LIMIT 1]; Account acc1 = [SELECT Id, Phone FROM Account WHERE Name= 'MyTestAccount1' LIMIT 1]; System.debug ( 'Account0.Phone=' +acc0.Phone + ',Account1.Phone=' acc1.Phone); } Account0.Phone=333-8781, Account1.Phone=333-8780 Account0.Phone=888-1515, Account1.Phone=999-2525 Account0.Phone=333-8780, Account1.Phone=333-8781 Account0.Phone=888-1515, Account1.Phone=999-1515.
Which statement results in an Apex compiler error? Map<Id,Leas> lmap = new Map<Id,Lead>([Select ID from Lead Limit 8]); Date d1 = Date.Today(), d2 = Date.ValueOf(‘2018-01-01’); Integer a=5, b=6, c, d = 7; List<string> s = List<string>{‘a’,‘b’,‘c’);.
Which three tools can deploy metadata to production? (Choose three.) Change Set from Developer Org Force.com IDE Data Loader Change Set from Sandbox Metadata API.
For which three items can a trace flag be configured? (Choose three.) Apex Trigger Apex Class Process Builder User Visualforce.
Which data type or collection of data types can SOQL statements populate or evaluate to? (Choose 3) A single sObject An integer A string A list of sObjects A Boolean.
A developer can use the debug log to see which three types of information? Choose 3 answers Resource usage and limits Database changes User login events HTTP callout to external systems Actions triggered by time-based workflow.
A developer is creating an application to track engines and their parts. An individual part 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.
Which two platform features allow for the use of unsupported languages? Choose 2 answers Heroku Acm App.json Buildpacks Docker.
Which standard field is required when creating a new contact record? LastName Name AccountId FirstName.
Which three statements are true regarding the @istest annotation? Choose 3 answers Products and pricebooks are visible in a test even if a class is annotated @istest (seealldata=false) A method annotated @istest (seealldata=false) in a class annotated @istest (seealladata=true) has access to all org data A method annotated @istest (seealldata=true) in a class annotated @istest (seealladata=false) has access to all org data Profiles are visible in a test even if a class is annotated @istest (seealldata=false) A class containing test methods counts toward the apex code liit regardless of any @istest annotation (Missed.
A developer needs an Apex method that can process Account or Contact records. Which method signature should the developer use? Public void doWork(Record theRecord) Public void doWork(sObject theRecord) Public void doWork(Account Contact) Public void doWork(Account || Contatc).
What should a developer working in a sandbox use to exercise a new test Class before the developer deploys that test production?Choose 2 answers The REST API and ApexTestRun method The Apex Test Execution page in Salesforce Setup. The Test menu in the Developer Console. The Run Tests page in Salesforce Setup.
How should the developer overcome this problem? While writing a test class that covers an OpportunityLineItem trigger, a Developer is unable to create a standard Pricebook since one already exist in the org. A. Use @IsTest(SeeAllData=true) and delete the existing standard Pricebook. B. Use @TestVisible to allow the test method to see the standard Pricebook. C. Use Test.getStandardPricebbokId()to get the standard Pricebook ID. D. Use Test.loaddata() and a Static Resource to load a standard Pricebook.
A Visual force page displays two fields named Phone Number and Email.User1 has access to Phone Number, but not to Email.User2 has access to Email, but not Phone NumberA developer needs to ensure that User1 can only see Phone Number, and User2 can only see Email.Which method can the developer use to achieve this? Schema isUpdateable() method. Schema isAccessible() method. Schema isReadable() method. Schema isCreateable() method.
What is a capability of the Force.com IDE? Choose 2 answers Roll back deployments. Run Apex tests. Download debug logs. Edit metadata components.
What are two characteristics of partial copy sandboxes versus full sandboxes? Choose 2 answers Includes a subset of metadata Requires a sandbox template Supports more frequent refreshes Provides more data record storage.
A company has a custom object named Region. Each account in salesforce can only be related to one region at a time, but this relationship is optional. Which type of relantionship should a developer use to relate an account to a region? Parent-child Master-detail Hierarchical Lookup.
Which is a valid apex assignment? Integer x=5 * 1,0 Integer = 5,0 Double x = 5 Float x = 5.0.
Which two approaches optimize test maintenance and support future declarative configuration changes? Choose 2 answers. Create a method that queries for valid records, then call this method within test methods. Create a methods that loads valid Account records from a static resources, then call this method within test methods. Create a method that performs a callout for valid records, then call this method within test methods. Create a method that creates valid records,then call this method within test methods.
Which two SOSL searches will returns records matching search criteria contained in any of the searchable texts fields on an object? Choose 2 answers [FIND 'Acme*' RETURNING Account,Opportunity]; [FIND 'Acme*' IN ANY FIELDS RETURNING Account,Opportunity]; [FIND 'Acme*' IN TEXT FIELDS RETURNING Account,Opportunity]; [FIND 'Acme*' IN ALL FIELDS RETURNING Account,Opportunity];.
A developer is creating a test coverage for a class and needs to insert records to validate functionality. Which method annotation should be used to create records for every method in the test class? @BeforeTest @isTest(SeeAllData=True) @TestSetup @PreTest.
Given the code block: Integer x; for (x =0; x<10; x+=2){ if (x==8) break; if (x==10) break; } system.debug(x); Which value will the system.debug display? 2 4 8 10.
What is a key difference between a Master-Detail Relationship and a Lookup Relationship? A Master-Detail Relationship detail record inherits the sharing and security of its master record. When a record of a master object in a Lookup Relationship is deleted, the detail records are also deleted. A Lookup Relationship is a required field on an object. When a record of a master object in a Master-Detail Relationship is deleted, the detail records are kept and not deleted.
What are two considerations for deciding to use a roll-up summary field? Choose 2 answer's partner. Roll-up summary can be performed on formula fields, but if their formula contains an #Error result, it may affect the summary value. Roll-up summary fields do not cause validation rules on the parent object unless that object is edited separately. Roll-up cannot be performed on formula fields. Roll-up cannot be performed on formula fields that use cross-object references or on-the-fly calculations such as NOW().
Potential home buyers working with a real estate company can make offers on multiple properties that are listed with the real estate company. Offer amounts can be modified; however, the property that has the offer cannot be modified after the offer is placed. What should be done to associate offers with properties in the schema for the organization? Create a master-detail relationship in the contact object to both the property and offer custom objects Create a lookup relationship in the property custom object to the offer custom object Create a master-detail relationship in the offer custom object to the property custom object Create a lookup relationship in the offer custom object to the property custom object.
Report abuse Terms of use
HOME
CREATE TEST
INFO
STADISTICS
RECORDS
Author's Tests