Skip to content

Conversation

srobotta
Copy link

Added examples on configuration settings, autocomplete options, language packs, and Moodle version requirements for Behat tests.

@Copilot Copilot AI review requested due to automatic review settings September 10, 2025 06:55
Copy link

netlify bot commented Sep 10, 2025

Deploy Preview for moodledevdocs ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit d701390
🔍 Latest deploy log https://app.netlify.com/projects/moodledevdocs/deploys/68c12c33e7a6f80008229a1c
😎 Deploy Preview https://deploy-preview-1433--moodledevdocs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances the Behat writing documentation by adding comprehensive examples for common testing scenarios. The additions provide practical guidance for developers writing Behat tests in Moodle environments.

  • Added documentation for configuration settings, autocomplete testing, language pack setup, and version-specific tests
  • Included code examples with Gherkin syntax for each new section
  • Provided specific implementation details for testing various Moodle features

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.


#### Configuration settings

For some tests you may need special configurations be present in you Moodle. These can be set as follows:
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a grammatical error in this sentence. It should be 'configurations to be present in your Moodle' instead of 'configurations be present in you Moodle'.

Suggested change
For some tests you may need special configurations be present in you Moodle. These can be set as follows:
For some tests you may need special configurations to be present in your Moodle. These can be set as follows:

Copilot uses AI. Check for mistakes.


#### Autocomplete options

To test that autocomplete options appear in a list as you type (such as the course search), a test can be witten
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word 'witten' should be 'written'.

Suggested change
To test that autocomplete options appear in a list as you type (such as the course search), a test can be witten
To test that autocomplete options appear in a list as you type (such as the course search), a test can be written

Copilot uses AI. Check for mistakes.

And the following "language packs" exist:
| language |
| fr |
| de |
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's trailing whitespace after the pipe character that should be removed for consistency.

Suggested change
| de |
| de |

Copilot uses AI. Check for mistakes.

| de |
| es |
```
This would have the additional language packs for French, German ans Spanish installed on the system. English
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word 'ans' should be 'and'.

Suggested change
This would have the additional language packs for French, German ans Spanish installed on the system. English
This would have the additional language packs for French, German and Spanish installed on the system. English

Copilot uses AI. Check for mistakes.

This would have the additional language packs for French, German ans Spanish installed on the system. English
is still present as well.

With the following test stepts the user may change the language:
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word 'stepts' should be 'steps'.

Suggested change
With the following test stepts the user may change the language:
With the following test steps the user may change the language:

Copilot uses AI. Check for mistakes.


#### Moodle version

Sometimes it's neccessary that a behat tests runs on a certain version of Moodle only.
Copy link
Preview

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word 'neccessary' should be 'necessary', and 'behat tests' should be 'Behat test' (singular) to match the context.

Suggested change
Sometimes it's neccessary that a behat tests runs on a certain version of Moodle only.
Sometimes it's necessary that a Behat test runs on a certain version of Moodle only.

Copilot uses AI. Check for mistakes.

The additions provide practical guidance for developers writing Behat tests in Moodle environments.

* Added documentation for configuration settings, autocomplete testing, language pack setup, and version-specific tests
* Included code examples with Gherkin syntax for each new section
* Provided specific implementation details for testing various Moodle features
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant