diff --git a/examples/modeling a many to many relationship with a form/test.hurl b/examples/modeling a many to many relationship with a form/test.hurl deleted file mode 120000 index 0dd017b9..00000000 --- a/examples/modeling a many to many relationship with a form/test.hurl +++ /dev/null @@ -1 +0,0 @@ -../../test.hurl \ No newline at end of file diff --git a/examples/modeling a many to many relationship with a form/test.hurl b/examples/modeling a many to many relationship with a form/test.hurl new file mode 100644 index 00000000..16795658 --- /dev/null +++ b/examples/modeling a many to many relationship with a form/test.hurl @@ -0,0 +1,33 @@ +GET http://localhost:8080/ +HTTP 200 +[Asserts] +body contains "Recent blog posts" +body contains "Write a post !" +body not contains "An error occurred" + +GET http://localhost:8080/write.sql +HTTP 200 +[Asserts] +body contains "Title of the post" +body contains "Main Topic" +body contains "Technology" +body contains "Travel" +body not contains "An error occurred" + +POST http://localhost:8080/write_submit.sql +Content-Type: application/x-www-form-urlencoded +`Title=Hurl%20many-to-many%20post&Content=Hurl%20content%20for%20the%20many-to-many%20form.&Main%20Topic=1&Topics%5B%5D=2&Topics%5B%5D=3` +HTTP 302 +[Captures] +location: header "Location" +[Asserts] +header "Location" matches "^post\\.sql\\?id=\\d+$" + +GET http://localhost:8080/{{location}} +HTTP 200 +[Asserts] +body contains "Hurl content for the many-to-many form." +body contains "Technology" +body contains "Travel" +body contains "Food" +body not contains "An error occurred"