The new flashcard feature is useful to memorize questions.
?Change your study mode
At any time, you can change the study mode, and alternate between the practice mode and the exam mode. In practice mode, you can configure for example the number of questions or tests, and other parameters to help you study.
Randomized | 10 Questions per Test | 20 Minutes | 70% to pass|
To re-configure your study mode again and change - for example - the number of tests, whether you have random questions and all other configuration parameters.
?Simulator Configuration
Auto-scroll: You can use the automatic scrolling of the questionnaire that occurs as soon as you answer one or all of the answers to a question correctly. Auto scrolling is activated if you answer a single answer, or as soon as you answer all the mandatory answers. Learning Mode: During learning mode you can get a real time result for your answer.
Free Test
Question: / 10
20:00Min. left
?Restart the current test
To restart the current test by clearing all your answers and the time used up to now. Warning: all answers will be lost.
Question: / 10
5.0(151 Votes)
Quiz
Question 1/101/10
Author and maintain workflows
Author and maintain workflows
Author and maintain workflows
A GitHub Actions workflow is triggered by a push event to the main branch. The workflow contains a single job with three steps. The first step uses the actions/checkout action. Which of the following best describes the purpose of actions/checkout in this context?
Select the answer:Select the answer
1 correct answer
A.
It downloads the workflow file from the repository to the runner.
B.
It checks out the repository code to the runner's workspace so subsequent steps can access files.
C.
It validates the syntax of the workflow YAML file before execution.
D.
It authenticates the runner with the repository using SSH keys.
Explanation: The actions/checkout action is essential in GitHub Actions workflows because it clones the repository code into the runner's workspace. This allows subsequent steps to access, build, test, or deploy the code. Without this step, the runner would have no access to the repository's source files. The action handles repository authentication and checks out the specified ref (branch, tag, or commit). It's typically the first step in any workflow that needs to work with repository code. While the workflow file itself is managed by GitHub and doesn't need to be checked out, the repository source code must be explicitly cloned for most CI/CD operations. ---
Right Answer: B
Quiz
Question 2/102/10
Consume workflows
Consume workflows
Consume workflows
A workflow consumes a reusable workflow and passes inputs like this: ``` with: environment: production debug: true ``` What must the reusable workflow do to receive these inputs?
Select the answer:Select the answer
1 correct answer
A.
Reference the inputs in its `env:` section.
B.
Define an `inputs:` section listing the input names and their types.
C.
Declare them as repository variables in the reusable workflow's repository.
D.
Use the `on:` keyword with a `workflow_call:` trigger that specifies input parameters.
Explanation: Reusable workflows must explicitly declare input parameters using the `inputs:` keyword at the workflow root level. Each input must specify its name, type (string, number, or boolean), and optionally a default value and description. When a workflow consumes the reusable workflow with `with:`, it passes values that match the declared inputs. The `workflow_call` trigger in the `on:` keyword indicates that the workflow can be called as a reusable workflow, but the actual input definitions go in the separate `inputs:` section. Within the reusable workflow, inputs are accessed using `${{ inputs.input_name }}` syntax. Type validation occurs automatically; passing a boolean to a string input or vice versa may cause errors depending on context. Reusable workflows also declare `outputs:` to expose data back to the consuming workflow. Inputs enable parameterization, making reusable workflows flexible for different use cases without code duplication. ---
Right Answer: B
Quiz
Question 3/103/10
Author and maintain actions
Author and maintain actions
Author and maintain actions
You are creating a custom action. The action defines: ``` runs: using: composite steps: - run: echo "Hello" ``` What type of action is this?
Select the answer:Select the answer
1 correct answer
A.
A JavaScript action that runs a script file.
B.
A composite action that combines multiple steps into a reusable unit.
C.
A Docker container action that runs in an isolated container.
D.
A shell script action that only works on Linux runners.
Explanation: Composite actions allow bundling multiple steps (shell, JavaScript, or other actions) into a single reusable action. The `using: composite` keyword indicates a composite action. Each step in a composite action runs sequentially in the same runner environment, sharing context like environment variables and workspace. Composite actions support inputs and outputs, enabling parameterization and result sharing. They're useful for grouping related steps that would otherwise be repeated across multiple workflows. Composite actions run on the host runner without the isolation provided by Docker container actions, making them faster but less isolated. The action.yml file defines the action's metadata, inputs, outputs, and steps. Composite actions can include other actions via `uses`, enabling action composition and reuse hierarchies. Unlike JavaScript or Docker actions, composite actions don't require compilation or containerization, making them quick to develop and modify. They're ideal for internal, simple workflows where shared step sequences provide value. ---
Right Answer: B
Quiz
Question 4/104/10
Manage GitHub Actions for the enterprise
Manage GitHub Actions for the enterprise
Manage GitHub Actions for the enterprise
An enterprise administrator wants to restrict GitHub Actions usage across all organizations. Which organization-level setting enables this control?
Select the answer:Select the answer
1 correct answer
A.
The "Actions" policy in the enterprise settings automatically applies to all organizations.
B.
The organization's "Settings > Actions" page has policies that override enterprise settings.
C.
Restricting actions requires modifying each organization's Actions runners configuration.
D.
Enterprise policies can be overridden at the organization level; each organization chooses independently.
Explanation: GitHub Actions policies exist at both enterprise and organization levels. Enterprise-level policies set default restrictions or requirements that apply to all organizations, but organizations can sometimes override these settings (depending on the specific policy). The organization's "Settings > Actions" page allows configuration of which actions are allowed, runner access, and workflow permissions. Some policies are enforced at the enterprise level and cannot be overridden; others allow organization-level customization. For example, an enterprise can enforce that all organizations require workflow approval or limit runners to self-hosted only. Organizations within the enterprise can then add additional restrictions beyond the enterprise baseline. To manage Actions across the enterprise, administrators should review both enterprise policies and organization-level settings. This hierarchical policy system allows flexibility while maintaining enterprise security and compliance requirements. Documentation should clarify which policies are enforced vs. advisory at each level. ---
Right Answer: B
Quiz
Question 5/105/10
Author and maintain workflows
Author and maintain workflows
Author and maintain workflows
You are defining a workflow trigger using the `on` keyword. You need the workflow to run whenever code is pushed to any branch AND when a pull request is created or updated. Which YAML syntax correctly expresses this?
Select the answer:Select the answer
1 correct answer
A.
on: [push, pull_request]
B.
on: push pull_request
C.
on: { push, pull_request }
D.
on: - push - pull_request
Explanation: GitHub Actions uses array syntax with square brackets to specify multiple trigger events. The correct syntax is `on: [push, pull_request]`, which tells GitHub to run the workflow both when code is pushed and when pull requests are created or updated. Each element in the array represents a distinct event type. Alternative valid formats include using a hyphenated list: `on:` followed by `- push` and `- pull_request` on separate lines. However, the array syntax `[push, pull_request]` is more compact and commonly used. Other syntaxes like curly braces or space-separated values are not valid YAML for workflow triggers in GitHub Actions. This is fundamental for setting up continuous integration pipelines that need to respond to multiple repository events. ---
Right Answer: A
Quiz
Question 6/106/10
Consume workflows
Consume workflows
Consume workflows
A consuming workflow invokes a reusable workflow through a job with the ID reusable. The reusable workflow exposes an output named build-version. How does a subsequent job access this output?
Select the answer:Select the answer
1 correct answer
A.
${{ needs.reusable.outputs.build-version }}
B.
${{ steps.reusable.outputs.build-version }}
C.
${{ jobs.reusable.outputs.build-version }}
D.
${{ env.build-version }}
Reusable workflows are invoked at the job level, not as a step. The calling job must have an ID, such as reusable, and a subsequent job must declare needs: reusable. The reusable workflow output is then accessed through needs.reusable.outputs.build-version. The reusable workflow itself maps build-version to the output of its internal build job.
Right Answer: A
Quiz
Question 7/107/10
Author and maintain actions
Author and maintain actions
Author and maintain actions
A custom JavaScript action needs to read the action's input parameter. The action.yml defines an input named `message`. How does the JavaScript code access this input?
Select the answer:Select the answer
1 correct answer
A.
`process.env.INPUT_MESSAGE`
B.
`process.argv[1]`
C.
`this.inputs.message`
D.
`github.context.inputs.message`
Explanation: GitHub Actions automatically converts input parameters to environment variables with the prefix `INPUT_` followed by the uppercase input name. An input named `message` becomes the environment variable `INPUT_MESSAGE`. JavaScript actions typically use the `@actions/core` library to simplify access with `core.getInput('message')`, which internally accesses the environment variable. If accessing the environment variable directly, use `process.env.INPUT_MESSAGE`. This convention applies to all action types that use environment-based input mechanisms. Outputs are set using `core.setOutput('key', 'value')` or by writing to the GITHUB_OUTPUT file. Environment variables are the standard mechanism for passing parameters to actions in GitHub Actions, ensuring consistency across action types. Understanding this input mechanism is critical for developing JavaScript actions that integrate with workflows. The @actions/core library provides additional utilities beyond input/output handling, including logging and error handling functions. ---
Right Answer: A
Quiz
Question 8/108/10
Manage GitHub Actions for the enterprise
Manage GitHub Actions for the enterprise
Manage GitHub Actions for the enterprise
An organization administrator creates a "Restrict to approved actions" policy for GitHub Actions. This policy is configured to allow only actions from the GitHub organization and a curated list. What happens when a workflow tries to use an action not on the approved list?
Select the answer:Select the answer
1 correct answer
A.
The workflow fails with an error before the action executes.
B.
The action runs, but a warning is logged in the audit log.
C.
The administrator receives an email notification about the violation.
D.
The action runs, but the step is marked as skipped in workflow results.
Explanation: When an organization restricts GitHub Actions to an approved list, workflows that reference unapproved actions fail before execution. GitHub's enforcement happens at the workflow parsing stage; unapproved actions are blocked and prevent the workflow from running. This is a hard block, not a warning or notification. Administrators can maintain an approved list including specific GitHub actions, marketplace actions, or internally developed actions. Patterns can include wildcards like `owner/action-*` to approve multiple actions from a specific owner. This policy improves security by preventing workflows from using malicious or untrusted actions. Teams must request approval for new actions, creating a governance process. The policy can be configured to allow actions from: all sources, GitHub-owned and Marketplace actions, or a specific allowed list. This feature is available for GitHub Enterprise and some GitHub.com plans, providing organization-level security controls. ---
Right Answer: A
Quiz
Question 9/109/10
Author and maintain workflows
Author and maintain workflows
Author and maintain workflows
A workflow needs to run on a schedule every day at 14:00 UTC. What is the correct YAML configuration for this scheduled trigger?
Select the answer:Select the answer
1 correct answer
A.
on: schedule = "0 14 * * *"
B.
on: cron: "0 14 * * *"
C.
on: schedule: - cron: "0 14 * * *"
D.
on: { schedule: cron "0 14 * * *" }
Explanation: GitHub Actions uses cron syntax for scheduled workflow runs. The correct structure requires the `schedule` keyword followed by a list of cron expressions. Each cron schedule is specified under the `- cron:` format. The cron expression "0 14 * * *" means minute 0, hour 14 (2 PM UTC), any day of month, any month, any day of week. This results in a daily execution at exactly 14:00 UTC. It's important to note that scheduled workflows have a maximum frequency of once every 5 minutes, though GitHub recommends using longer intervals to avoid server strain. The schedule trigger is useful for maintenance tasks, periodic backups, or nightly builds. When a scheduled workflow runs, it checks out the default branch automatically. ---
Right Answer: C
Quiz
Question 10/1010/10
Consume workflows
Consume workflows
Consume workflows
A workflow calls a reusable workflow and needs to monitor its success or failure. Which job status does the calling job have if the reusable workflow fails?
Select the answer:Select the answer
1 correct answer
A.
The calling job succeeds; the reusable workflow's failure is logged separately.
B.
The calling job fails if the reusable workflow fails and `continue-on-error` is not set.
C.
The calling job always succeeds, regardless of the reusable workflow's status.
D.
The calling job status depends on the reusable workflow's use of `continue-on-error`.
Explanation: When a job calls a reusable workflow using `uses:`, the calling job's status is directly tied to the reusable workflow's status by default. If the reusable workflow fails, the calling job fails, causing the entire workflow to fail (unless subsequent jobs use conditions to continue). This is the expected behavior for workflow composition; a failed reusable workflow should fail the consuming workflow. However, if the step that calls the reusable workflow has `continue-on-error: true`, the calling job continues even if the reusable workflow fails. This allows error recovery logic or conditional handling of failures. Inside the reusable workflow, individual steps can use `continue-on-error`, which affects the reusable workflow's overall status if all steps fail or if no steps run successfully. The calling workflow can inspect the reusable workflow's status using conditionals like `if: failure()` on subsequent steps or jobs to implement custom error handling. This behavior ensures that workflow failures propagate appropriately through the call chain. ---
GH-200: GitHub Actions Practice test unlocks all online simulator questions
Thank you for choosing the free version of the GH-200: GitHub Actions practice test! Further deepen your knowledge on Microsoft Simulator; by unlocking the full version of our GH-200: GitHub Actions Simulator you will be able to take tests with over 200 constantly updated questions and easily pass your exam. 98% of people pass the exam in the first attempt after preparing with our 200 questions.
What to expect from our GH-200: GitHub Actions practice tests and how to prepare for any exam?
The GH-200: GitHub Actions Simulator Practice Tests are part of the Microsoft Database and are the best way to prepare for any GH-200: GitHub Actions exam. The GH-200: GitHub Actions practice tests consist of 200 questions and are written by experts to help you and prepare you to pass the exam on the first attempt. The GH-200: GitHub Actions database includes questions from previous and other exams, which means you will be able to practice simulating past and future questions. Preparation with GH-200: GitHub Actions Simulator will also give you an idea of the time it will take to complete each section of the GH-200: GitHub Actions practice test . It is important to note that the GH-200: GitHub Actions Simulator does not replace the classic GH-200: GitHub Actions study guides; however, the Simulator provides valuable insights into what to expect and how much work needs to be done to prepare for the GH-200: GitHub Actions exam.
GH-200: GitHub Actions Practice test therefore represents an excellent tool to prepare for the actual exam together with our Microsoft practice test . Our GH-200: GitHub Actions Simulator will help you assess your level of preparation and understand your strengths and weaknesses. Below you can read all the quizzes you will find in our GH-200: GitHub Actions Simulator and how our unique GH-200: GitHub Actions Database made up of real questions:
Info quiz:
Quiz name:GH-200: GitHub Actions
Total number of questions:200
Number of questions for the test:50
Pass score:80%
You can prepare for the GH-200: GitHub Actions exams with our mobile app. It is very easy to use and even works offline in case of network failure, with all the functions you need to study and practice with our GH-200: GitHub Actions Simulator.
Use our Mobile App, available for both Android and iOS devices, with our GH-200: GitHub Actions Simulator . You can use it anywhere and always remember that our mobile app is free and available on all stores.
Our Mobile App contains all GH-200: GitHub Actions practice tests which consist of 200 questions and also provide study material to pass the final GH-200: GitHub Actions exam with guaranteed success.
Our GH-200: GitHub Actions database contain hundreds of questions and Microsoft Tests related to GH-200: GitHub Actions Exam. This way you can practice anywhere you want, even offline without the internet.