Skip to content

Improve URL spec suite #97

@dentarg

Description

@dentarg

I think that we need to create a new structure for url_spec.rb. It worked well with one-dimensional arrays when we just asserted invalid/valid, but since then we added many corner cases, and it would be good to be able to assert each and every part on many of the URLs we have in the spec file. We want to do this for the non-normalized version and the normalized version.

One example of a structured way of testing many inputs is https://github.com/weppos/publicsuffix-ruby/blob/v2.0.2/test/tests.txt, but it's only one output, so I think we have to come up with something slightly more advanced.

I have also started to add comments about some of the URLs in the spec, might be something we can even incorporate in the rspec output, if we find a good structure.

A bit related to the table idea for examples, #96.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions