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

Add tests borrowed from Hiccup's test suite and make small tweaks to match Hiccup/Reagent behavior. #4

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Commits on Aug 1, 2023

  1. WIP: Add tests borrowed from Hiccup's test suite.

    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    e359271 View commit details
    Browse the repository at this point in the history
  2. Support symbols and strings as tag names.

    For example, `['div]` and `["div"] are now allowed.
    
    This ensures compatability with the original Hiccup and also Reagent
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    2df900d View commit details
    Browse the repository at this point in the history
  3. Document discrepancies

    Document a few discrepancies I've noticed between our libraryy and
    others.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    c1f0958 View commit details
    Browse the repository at this point in the history
  4. Update test to check for correct exception.

    We throw a different exception than Hiccup does.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    eb458ef View commit details
    Browse the repository at this point in the history
  5. Make the attribute id take priority over the tag.

    This matches the behavior of Reagent and the original Hiccup.
    
    For example, in `[:div#foo {:id "bar"}]`, the id would be bar and not
    foo.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    a857622 View commit details
    Browse the repository at this point in the history
  6. Tweak tests to account for non-semantic differences.

    Our output differs slightly in ways that don't make any semantic
    difference.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    70cd93e View commit details
    Browse the repository at this point in the history
  7. Improve explanation of implementation differences.

    Revise wording and add bullet about `style` attribute.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    fb9d086 View commit details
    Browse the repository at this point in the history
  8. Clean up code

    Remove some issues that were in the original Hiccup tests.
    Alys Brooks committed Aug 1, 2023
    Configuration menu
    Copy the full SHA
    c2dd8a5 View commit details
    Browse the repository at this point in the history