Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First pass at phpunit tests #6

Merged
merged 20 commits into from
Oct 9, 2020
Merged

Conversation

dsawardekar
Copy link
Collaborator

Requirements

First attempt at unit tests for the PHP code.

Description of the Change

This PR includes tests for,

  • Admin Bar & Menus
  • Assets manager
  • Classic Editor Toggle manager

Alternate Designs

NA

Benefits

Improved maintainability and test coverage.

Possible Drawbacks

NA

Verification Process

vendor/bin/phpunit

Running as single site... To run multisite, use -c tests/phpunit/multisite.xml
Not running ajax tests. To execute these, use --group ajax.
Not running ms-files tests. To execute these, use --group ms-files.
Not running external-http tests. To execute these, use --group external-http.
PHPUnit 7.5.20 by Sebastian Bergmann and contributors.

....................                                              20 / 20 (100%)

Time: 440 ms, Memory: 30.00 MB

OK (20 tests, 27 assertions)

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Applicable Issues

NA

Changelog Entry

Added initial PHPUnit Tests.

@dsawardekar dsawardekar changed the title Feature/first pass at phpunit tests First pass at phpunit tests Sep 30, 2020
@jeffpaul jeffpaul added this to the 1.2.0 milestone Sep 30, 2020
@tlovett1
Copy link
Member

tlovett1 commented Oct 6, 2020

Hey @dsawardekar we changed the plugin name to "Convert to Blocks. Can you refactor the PR please?

Copy link
Member

@jeffpaul jeffpaul left a comment

Choose a reason for hiding this comment

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

Please update to "Convert to Blocks" naming

@dsawardekar
Copy link
Collaborator Author

@tlovett1 @jeffpaul I have refactored the PR to reflect the new name. And also fixed the failing tests and linter warnings.

@tlovett1 tlovett1 merged commit 7183062 into develop Oct 9, 2020
@jeffpaul jeffpaul modified the milestones: 1.0.1, 1.0.0 Jan 14, 2021
@jeffpaul jeffpaul deleted the feature/first-pass-at-phpunit-tests branch February 8, 2021 20:43
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.

5 participants