Salesforce DX Flashcards

1
Q
What is the source of truth for source-driven development?
A. Sandbox
B. Version control system
C. Production org
D. Salesforce DX project
A

B. Version control system

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the advantages of source-driven development?
A. Ability to build development orgs directly from source
B. All code and customizations are intermingled in the source repo
C. Agile release models allow more frequent, independent releases
D. A and B
E. A and C

A

E. A and C

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How does Salesforce DX define an artifact?
A. All the code in your production org
B. The metadata in your sandbox
C. A group of code and customizations you want to release together
D. The package you deploy to your production org

A

C. A group of code and customizations you want to release together

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Scratch orgs provide:
A. A Salesforce org that multiple developers use at the same time
B. A dedicated and disposable Salesforce environment for a developer and their project
C. A copy of an existing sandbox
D. A and B

A

B. A dedicated and disposable Salesforce environment

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the role of sandboxes in source-driven development?
A. You don’t use sandboxes in the Salesforce DX application life cycle
B. You use sandboxes for user acceptance testing and as a staging environment.
C. It’s a starting point for the development process.
D. It’s where you install your package during continuous delivery testing.
E. B and D

A

E. B and D

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How does the Salesforce CLI increase your productivity?
A. It lets you change scratch org shape.
B. It does the dishes.
C. You can create scripts for repetitive tasks, for build automation, or to run tests.
D. It contains commands that help you directly interact with your version control system.

A

C. You can create scripts for repetitive tasks, for build automation, or to run tests.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

The Salesforce DX project:
A. Is an exact copy of your development sandbox
B. Does not have to be checked into source control
C. Contains your source and Salesforce DX configuration files
D. Contains only Salesforce DX configuration files

A

C. Contains your source and Salesforce DX configuration files

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How does Salesforce DX facilitate change tracking?
A. It tracks changes you make locally, but you need to manually track changes you make in your scratch org.
B. It transforms large source files into smaller files, which provide more project flexibility and reduce merge conflicts.
C. It keeps track of both changes you make locally as well as any in your scratch org.
D. A and B
E. B and C

A

E. B and C

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Use scratch orgs in the development process to:
A. Perform declarative (point-and-click) development and other tasks directly in an org.
B. Maintain all your source for posterity.
C. Develop new features over several releases.
D. Facilitate team development by everyone sharing a scratch org.

A

A. Perform declarative (point-and-click) development and other tasks directly in an org.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How do scratch orgs support testing and continuous integration?
A. You can refresh them once a day so you can run tests.
B. You can pull source and metadata from the scratch org for testing purposes.
C. Best practices dictate that you use the same org for development and testing.
D. You can spin up a new scratch org specifically for testing and CI.

A

D. You can spin up a new scratch org specifically for testing and CI.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Use sandboxes for continuous delivery and user acceptance testing to:
A. Provide new features directly to your customers.
B. Test the same process you’ll use to deploy and release to the production org.
C. Develop new features.
D. Create the package.xml file.

A

B. Test the same process you’ll use to deploy and release to the production org.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What use cases are ideal for shifting to a modular project-based approach?
A. You’re developing a distinct application.
B. Your production org isn’t complex and you make minimal changes month over month.
C. You’re developing functionality that multiple projects share.
D. Your sales automation customizations can’t be tested independently of the rest of the org metadata.

A

A. You’re developing a distinct application.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

In what scenario do you need to be careful when creating projects?
A. When a project is a distinct application
B. When your team is ready to build and deliver in a separate release cycle
C. When your team works on multiple projects
D. When projects share metadata components

A

D. When projects share metadata components

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Use Dev Hub to:
A. Manage sandbox and production orgs through the CLI.
B. Create and mange scratch orgs.
C. Move configurations from your sandbox yo your scratch org.
D. Create a scratch org for another team member.

A

B. Create and mange scratch orgs.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
How do you list all available CLI commands?
A. sfdx force:commands:view
B. sfdx force:list:help
C. sfdx force:doc:commands:list
D. sfdx force:doc:commands:view
E. sfdx force:commands:doc:display
A

C. sfdx force:doc:commands:list

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What information does the sfdx-project.json file contain?
A. Information required to track source and metadata with your scratch org.
B. Configuration information that determines scratch org shape.
C. A list of the scratch orgs you’ve created in the Dev Hub.
D. Configuration information for your sandbox and production orgs.

A

A. Information required to track source and metadata with your scratch org.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q
What is the CLI command to create a project called MyNewApp?
A. sfdx force:project:create -a MyNewApp
B. sfdx force:create:project -a MyNewApp
C. sfdx force:project:create -n MyNewApp
D. sfdx force:create:project -n MyNewApp
A

C. sfdx force:project:create -n MyNewApp

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What’s an example of the CLI command to import existing Accounts sample data in a different project?
A. sfdx force:data:tree -q Account.json
B. sfdx force:data:tree:import -contenttype data/Account.json
C. sfdx force:data:tree:import -sobjecttreefiles data/Account.json
D. sfdx force:data:tree:import -s Account.json

A

C. sfdx force:data:tree:import -sobjecttreefiles data/Account.json

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q
What's the CLI command to create a new Apex class called NewClass in the force-app folder?
A. sfdx force:apex:class:create -n NewClass -d force-app/main/apex/classes.
B. sfdx force:apex:class:create -n NewClass -d force-app/main/default/classes.
C. sfdx force:apex:class:create -n NewClass -f force-app/main/apex.
D. sfdx force:apex:class:create -n NewClass -f force-app/main/default/classes.
A

D. sfdx force:apex:class:create -n NewClass -d force-app/main/default/classes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What’s the CLI command to create a new Lightning component called ListView in the force-app folder?
A. sfdx force:lightning:component:create -n ListView -f force-app/main/default/aura.
B. sfdx force:lightning:component:create -n ListView -d force-app/main/aura.
C. sfdx force:lightning:component:create -n ListView -f force-app/main/default/lightning.
A. sfdx force:lightning:component:create -n ListView -d force-app/main/default/aura.

A

A. sfdx force:lightning:component:create - ListView -f force-app/main/default/aura.

21
Q

What’s the CLI command to synchronize changes in your local project to a scratch org with the alias MyScratchOrg?
A. sfdx force:org:push -a MyScratchOrg
B. sfdx force:source:push -a MyScratchOrg
C. sfdx force:source:push -u MyScratchOrg
D. sfdx force:source:sync -u MyScratchOrg

A

C. sfdx force:source:push -u MyScratchOrg

22
Q

What’s the CLI command to assign a permission set called MyPermSet to provide access to objects in an org with the alias MyTP?
A. sfdx force:permset:assign -n MyPermSet
B. sfdx force:user:permset:assign -n MyPermSet -u MyTP
C. sfdx force:org:permset:assign -n MyPermSet -a MyTP
D. sfdx force:user:permset:assign -n MyPermSet -a MyTP

A

B. sfdx force:user:permset:assign -n MyPermSet -u MyTP

23
Q

Who are unlocked packages primarily designed for?
A. Salesforce Partners who want to publish on AppExcahnge.
B. Customers who develop and deploy in-house business apps
C. Development teams who want to distribute Lightning components on AppExcahnge
D. A and C

A

B. Customers who develop and deploy in-house business apps

24
Q

What is the Package Development model?
A. Using change sets to deploy updated metadata to the production org
B. Promoting the org as the source of truth
C. An iterative process where you organize your metadata into packages
D. A process that requires you to track all your metadata changes in a spreadsheet

A

C. An iterative process where you organize your metadata into packages

25
Q

How do you deploy metadata in this new model to sandboxes for user acceptance testing?
A. run force:source:push from the Salesforce CLI
B. Use the ANT migration tool to deploy metadata
C. Install the package version in the org.
D. Use change sets to move the metadata between orgs.
E. B and D

A

C. Install the package version in the org.

26
Q

Which of the following about unlocked packages is true?
A. They have a strict set of manageability rules
B. They can be installed on only scratch orgs and sandboxes
C. They provide flexibility to make changes directly in the org.
D. They don’t support dependencies between packages.

A

C. They provide flexibility to make changes directly in the org.

27
Q

What should you do when you’re starting to organize your metadata into packages?
A. Put all your metadata into one unlocked package
B. Identify a set of related metadata that represents a functional unit.
C. Convert you source to Salesforce DX format using force:source:convert
D. Create a package with a namespace to make sure API name don’t change.
E: B and C

A

B. Identify a set of related metadata that represents a functional unit.

28
Q
What can an unlocked package depend on?
A. Another unlocked package
B. An AppExchange App
C. A change set created in the org
D. A and B
A

D. A and B

29
Q

If you are customizing Sales Cloud so that it shares some functionality with Service Cloud, which model would you select?
A. App-based and Shared Library
B. Customizations-based
C. Shared Library
D. App-based and Customizations-based
E. Customizations-based and Shared Library

A

E. Customizations-based and Shared Library

30
Q

Which of the following outcomes can be realized by teams who do not use version control?
A. Overwriting changes made by other users.
B. Corruption of shared file servers
C. Deployment failures
D. Merge conflicts

A

A. Overwriting changes made by other users.

31
Q

How does version control ease the burden of collaboration among team members?
A. Maintaining regular backups of team member’s laptops.
B. Enforcing strict rules and processes on team members.
C. Provides a one-size-fits-all solution for teams to collaborate.
D. Provides a way to organize work from many team members.

A

D. Provides a way to organize work from many team members.

32
Q

GitHub enhances collaboration in teams by:
A. Providing a group chat functionality
B. Providing visibility into the team’s work and the ability review code.
C. Providing the ability to share screens
D. Providing a toll-free number to use for web meetings

A

B. Providing visibility into the team’s work and the ability review code.

33
Q

What is the key relationship between Git and GitHub?
A. Git is a VCS. GitHub is a collaboration platform that is built on top of Git.
B. GitHub is Git for teams.
C. Git and GitHub is the same product, but with different names based on whether you use it locally or through te web browser.
D. GitHub is the graphical user interface for Git, but it has identical functionality.

A

A. Git is a VCS. GitHub is a collaboration platform that is built on top of Git.

34
Q

Which of the following is considered an essential tool in the modern developer’s toolkit?
A. A shared drive for maintaining backups of project versions.
B. A Flash drive for sharing files with team members.
C. CI - Continuous Integration
D. A backup strategy for compiled versions of your project.

A

C. CI - Continuous Integration

35
Q

GitHub helps you customize your workflows with:
A. A growing list of integration partners like Waffle.io or ZenHub.
B. A built-in lightweight project management solution.
C. The ability to integrate with CI and continuous deployment applications
D. All of the above

A

D. All of the above

36
Q
Where can you view the files within a repository on GitHub?
A. Code tab
B. Issues tab
C. Pull Request tab
D. Projects tab
A

A. Code tab

37
Q
Which account type is best suited for large, diverse teams with many projects?
A. Individual
B. Organization
C. Team
D. Administrator
A

B. Organization

38
Q

What is the primary function of Issues in GitHub?
A. Making commits
B. Comparing branches
C. Having conversations
D. Cross-referencing other issues and pull requests

A

C. Having conversations

39
Q
What is the first step of the GitHub flow?
A. Merging
B. Commiting 
C. Branching
D. Cloning
A

C. Branching

40
Q
Which of the following commands is used to synchronize the remote and local working environments?
A. git pull
B. git merge
C. git status
D. git commit
A

A. git pull

41
Q
What command moves a file from the working directory to the staging area?
A. git status
B. git remote -v
C. git staging
D. git add
A

D. git add

42
Q

Typically, how long should branches exist?
A. It doesnt matter
B. Shorter is better all the time
C. Shorter is best, but long lived branches may be appropriate in some cases.
D. Long-lived branches are better for small teams

A

C. Shorter is best, but long lived branches may be appropriate in some cases.

43
Q

Merge conflicts happen when:
A. Two or more people are working on the same file
B. Two or more peope are working on the same file at the same time.
C. Two or more branches have had changes on the same part of the same file since the branches were created.
D. Two or more branches have had changes on the same part of the same file.

A

C. Two or more branches have had changes on the same part of the same file since the branches were created.

44
Q

What is the right amount of change to include in a commit?
A. About 2 hours’ worth of work
B. All of the changes necessary to implement the requested feature.
C. A single line of code
D. Enough for a small, logical unit of code

A

D. Enough for a small, logical unit of code

45
Q
What hashing algorithm does Git use to identify commits?
A. MD5
B. SHA-1
C. SHA-2
D. AES
A

C. SHA-1

46
Q
What command is used to see the history of commits?
A. git status
B. git revert
C. git log
D. git history
A

C. git log

47
Q
What is the safest command to use to change history?
A. git reset --soft
B. git commit --amend
C. git revert
D. git rebase
A

C. git revert

48
Q

How is rebase used in relation to a merge?
A. A rebase is the same as a merge
B. A rebase lets you move from a fast-forward to a
recursive merge scenario.
C. A rebase lets you move from a recursive to a fast-forward merge scenario.
D. A rebase lets you select the merge strategy you would like to use.

A

C. A rebase lets you move from a recursive to a fast-forward merge scenario.