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

Creating a node with a certain URL alias #645

Open
brockfanning opened this issue Apr 5, 2023 · 1 comment
Open

Creating a node with a certain URL alias #645

brockfanning opened this issue Apr 5, 2023 · 1 comment

Comments

@brockfanning
Copy link

Hi all, does anyone know if any of the available step definitions allow for creating a node with a particular URL alias?

My goal is to create a node a certain field value and a certain URL alias, so that in the next step I can visit it. For example, something like:

Given page content:
  | title       | field_my_field | url_alias |
  | My title    | My field value | /my-alias |
And I am on "/my-alias"
...

But the above doesn't work for me (/my-alias appears to be a page-not-found).

Thank you for any tips!

@kdahbi
Copy link

kdahbi commented Jul 9, 2023

Try to use field called "path":

And "test" content:
      | title           | field_valor   | body          | status | path |
      | Test title      | 10            | <p>Text</p>   | 1 | /path1 |
      | Test title 2    | 5             | <p>Text</p>   | 0 | /path2 |
    When I visit "/path1"
    Then response status code should be 200
    When I send a GET request to "/path1"    
    Then response status code should be 200

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

No branches or pull requests

2 participants