Copilot commented on code in PR #15410: URL: https://github.com/apache/grails-core/pull/15410#discussion_r2825275228
########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/BookListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class BookListPage extends Page { + + static String pageTitle = 'Book List' + + static url = 'book/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes (e.g., '/book/index' instead of 'book/index'). This pattern is consistently used in the geb subproject (HomePage, UploadPage) and scaffolding-fields subproject (EmployeeListPage, DepartmentListPage). ```suggestion static url = '/book/index' ``` ########## grails-test-examples/app3/src/integration-test/groovy/app3/pages/LoginAuthPage.groovy: ########## @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package app3.pages + +import geb.Page + +class LoginAuthPage extends Page { + + static String pageTitle = 'My Plugin Login Auth' + + static url = 'login/auth' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/login/auth' ``` ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/BarListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class BarListPage extends Page { + + static String pageTitle = 'Bar List' + + static url = 'bar/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes (e.g., '/bar/index' instead of 'bar/index'). ```suggestion static url = '/bar/index' ``` ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/BookShowPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class BookShowPage extends Page { + + static String pageTitle = 'Show Book' + + static url = 'book/show' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes (e.g., '/book/show' instead of 'book/show'). ```suggestion static url = '/book/show' ``` ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/pages/AdminPagePage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.pages + +import geb.Page + +class AdminPagePage extends Page { Review Comment: The class name "AdminPagePage" is redundant with "Page" appearing twice. Consider renaming to "AdminPage" for clarity and consistency with other Page Objects like "HomePage", "BookListPage", etc. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/BookFunctionalSpec.groovy: ########## @@ -28,24 +31,23 @@ class BookFunctionalSpec extends ContainerGebSpec { void "Test that when the /viewBooks URL is hit it redirects to the book list"() { when: "We go to the book URI" - go "/book/index" + to(BookListPage) then: "Then thew show book view is rendered" - title == "Book List" + at(BookListPage) } void "Test that a book was created in the Bootstrap class"() { when: "We go to the book URI" - go('/book/show/1') + to(BookShowPage, 1) Review Comment: Using `to(BookShowPage, 1)` will not work as expected because the BookShowPage URL doesn't define parameter placeholders. Geb's `to()` method with parameters expects the Page Object's URL to be defined as a closure or list that handles the parameters (e.g., `static url = { id -> "/book/show/$id" }`). The original `go('/book/show/1')` approach was more appropriate for this case, or the BookShowPage URL needs to be updated to accept parameters. ```suggestion go "/book/show/1" ``` ########## grails-test-examples/app2/src/integration-test/groovy/app2/pages/FooListPage.groovy: ########## @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package app2.pages + +import geb.Page + +class FooListPage extends Page { + + static String pageTitle = 'Foo List' + + static url = 'foo/index?user=admin' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/foo/index?user=admin' ``` ########## grails-test-examples/hibernate5/grails-hibernate/src/integration-test/groovy/functional/tests/pages/BookShowPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookShowPage extends Page { + + static String pageTitle = 'Show Book' + + static url = 'book/show' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/mongodb/hibernate5/src/integration-test/groovy/functional/tests/pages/AuthorShowPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class AuthorShowPage extends Page { + + static String pageTitle = 'Show Author' + + static url = 'author/show' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/ConventionLayoutPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class ConventionLayoutPage extends Page { + + static String pageTitle = 'Convention Layout' + + static url = 'layoutByConvention' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/layoutByConvention' ``` ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/LoginAuthPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class LoginAuthPage extends Page { + + static String pageTitle = 'My Plugin Login Auth' + + static url = 'login/auth' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/login/auth' ``` ########## grails-test-examples/mongodb/hibernate5/src/integration-test/groovy/functional/tests/pages/BookShowPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookShowPage extends Page { + + static String pageTitle = 'Show Book' + + static url = 'book/show' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/FooLayoutSnippetPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class FooLayoutSnippetPage extends Page { + + static String pageTitle = 'Foo Layout' + + static url = 'layoutSpecifiedByProperty/snippetView' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/layoutSpecifiedByProperty/snippetView' ``` ########## grails-test-examples/mongodb/base/src/integration-test/groovy/functional/tests/pages/BookShowPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookShowPage extends Page { + + static String pageTitle = 'Show Book' + + static url = 'book/show' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/ActionReturnsNullPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class ActionReturnsNullPage extends Page { + + static String pageTitle = 'Action Which Returns Null GSP' + + static url = 'misc/actionWhichReturnsNull' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/misc/actionWhichReturnsNull' ``` ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/admin/pages/AdminReportPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.admin.pages + +import geb.Page + +class AdminReportPage extends Page { + + static String pageTitle = 'Admin Report' + + static url = 'myAppTest/admin/report/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/hibernate5/grails-hibernate/src/integration-test/groovy/functional/tests/pages/BookListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookListPage extends Page { + + static String pageTitle = 'Book List' + + static url = 'book/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/book/index' ``` ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/PartialPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class PartialPage extends Page { + + static String pageTitle = 'Welcome to My Partial' + + static url = 'layoutTemplate/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/layoutTemplate/index' ``` ########## grails-test-examples/mongodb/base/src/integration-test/groovy/functional/tests/pages/BookListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookListPage extends Page { + + static String pageTitle = 'Book List' + + static url = 'book/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/FooListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class FooListPage extends Page { + + static String pageTitle = 'Foo List' + + static url = 'foo/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes (e.g., '/foo/index' instead of 'foo/index'). ```suggestion static url = '/foo/index' ``` ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/admin/pages/ReportPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.admin.pages + +import geb.Page + +class ReportPage extends Page { + + static String pageTitle = 'Admin Report' + + static url = 'myAppTest/report/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/mongodb/hibernate5/src/integration-test/groovy/functional/tests/pages/AuthorListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class AuthorListPage extends Page { + + static String pageTitle = 'Author List' + + static url = 'author/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app2/src/integration-test/groovy/app2/pages/PageNotFoundPage.groovy: ########## @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package app2.pages + +import geb.Page + +class PageNotFoundPage extends Page { + + static String pageTitle = 'Page Not Found' + + static url = 'foo/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/foo/index' ``` ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/pages/FrontendPagePage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.pages + +import geb.Page + +class FrontendPagePage extends Page { Review Comment: The class name "FrontendPagePage" is redundant with "Page" appearing twice. Consider renaming to "FrontendPage" for clarity and consistency with other Page Objects like "HomePage", "BookListPage", etc. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/BookCreatePage.groovy: ########## @@ -0,0 +1,33 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class BookCreatePage extends Page { + + static String pageTitle = 'Create Book' + + static url = 'book/create' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes (e.g., '/book/create' instead of 'book/create'). ```suggestion static url = '/book/create' ``` ########## grails-test-examples/mongodb/hibernate5/src/integration-test/groovy/functional/tests/pages/BookListPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functional.tests.pages + +import geb.Page + +class BookListPage extends Page { + + static String pageTitle = 'Book List' + + static url = 'book/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/exploded/src/integration-test/groovy/exploded/pages/LoginAuthPage.groovy: ########## @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package exploded.pages + +import geb.Page + +class LoginAuthPage extends Page { + + static String pageTitle = 'My Plugin Login Auth' + + static url = 'login/auth' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/login/auth' ``` ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/pages/AdminPagePage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.pages + +import geb.Page + +class AdminPagePage extends Page { + + static String pageTitle = 'Admin Page' + + static url = 'myAppTest/admin/page/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/namespaces/src/integration-test/groovy/namespaces/pages/FrontendPagePage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package namespaces.pages + +import geb.Page + +class FrontendPagePage extends Page { + + static String pageTitle = 'Frontend Page' + + static url = 'myAppTest/page/index' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ########## grails-test-examples/app1/src/integration-test/groovy/functionaltests/pages/FooLayoutPage.groovy: ########## @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package functionaltests.pages + +import geb.Page + +class FooLayoutPage extends Page { + + static String pageTitle = 'Foo Layout' + + static url = 'layoutSpecifiedByProperty' Review Comment: The static url property should have a leading slash to match the established codebase convention. All existing Page Objects in the repository use leading slashes. ```suggestion static url = '/layoutSpecifiedByProperty' ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
