Proper testing url creation

Hi!

I have just started to learn proper, started to read Fred’s book about it.

But I got stuck when I tried to make a url tester that could try different combinations and characters.

How could a model look when I want to combine say a binding and none binding.

v1/user/123

I will continue read Fred’s book but are happy to get more information about writing this kind of tests.

3 Likes

What about http_uri? I mean http_uri:parse/1 for parse URLs. Looks like this can help you get all data from URL.

2 Likes

It is more generating then parsing.

Want to be able to generate all kinds of url.

3 Likes

Oh, generation of URLs got it - then maybe uri_string:compose_query/1? I use this tool for build URLs in my few projects.

3 Likes