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

Unit tests+header option #102

Open
wants to merge 2 commits into
base: lib
Choose a base branch
from
Open

Unit tests+header option #102

wants to merge 2 commits into from

Conversation

Znarkus
Copy link

@Znarkus Znarkus commented May 24, 2013

Hi! I started work on unit tests (phpunit). Also added configuration option to change header elements.

@michelf
Copy link
Owner

michelf commented May 24, 2013

The test suite already exists here: https://github.com/michelf/mdtest
Read my comment here if you want to improve it: michelf/mdtest#3

@mtibben
Copy link

mtibben commented Jun 18, 2014

It would be nice to have the tests in this repo, or at least linked in the Readme. My first thoughts when coming across this lib was "Oh god, there is no test suite".

Also, it looks like it would be fairly trivial to use your existing tests with PhpUnit

@michelf
Copy link
Owner

michelf commented Jun 18, 2014

There a link on the Readme under Development and Testing (added after this issue was first opened):
https://github.com/michelf/php-markdown#development-and-testing

The reason it's a separate tool is to allow it to be used to test others implementations which aren't necessarily in PHP. Also a plain string equality test (as performed in this pull) isn't the ideal comparison tool: MDTest performs some normalization to ignore insignificant whitespace and attributes ordered differently.

@michaelbutler
Copy link
Contributor

This could either be deleted or moved to the test/ directory that was recently created.

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.

4 participants