-
Improvement
-
Resolution: Duplicate
-
Minor
-
None
-
4.4
I noticed that we have few tests in core manually creating badges:
And I navigate to "Badges > Add a new badge" in current page administration
|
And I set the following fields to these values:
|
| id_name | Badge 1 |
|
| id_description | Badge 1 |
|
And I upload "blocks/badges/tests/fixtures/badge.png" file to "Image" filemanager
|
And I press "Create badge"
|
However it's possible to create badges using data generators:
Given the following "core_badges > Badge" exists:
|
| name | Badge #1 |
|
| status | 0 |
|
| version | 1 |
|
| language | en |
|
| description | Test badge description |
|
| image | badges/tests/behat/badge.png |
|
| imageauthorurl | http://author.example.com |
|
| imagecaption | Test caption image |
|
As part of this issue, we should look for the following steps:
- I navigate to "Badges > Add a new badge" in current page administration
- I press "Create badge"
and see if we can convert those to use the data generator above.
Please note to leave "Add a badge" scenario untouched so we have at least one manual test using the UI to create a new badge.