Created on 13 April 2016, over 8 years ago
Updated 18 April 2024, 8 months ago

Problem/Motivation

Add test cases for testing the functionality of the module.

Proposed resolution/ Test Case scenarios

Most useful feature is the search restrictions and this is also requires the most indepth knowledge of Drupal to implement.

Personally, I was going to tackle this from the ground up (as opposed to a pure port / coder like upgrade). If you take this approach, you could do test driven development (the best, but slowest), and tackle the various components 1 by 1.

Search user permissions & query alter to exclude
Individual node exclusions (and migration support for D7 - D8)

Then the various other bits from the forms. Very roughly, these fall into the following categories.

Search limits
Search labels
Search form alters

But if you have no idea of what a query alter is, I'd definitely reverse this order, form alters are the easiest things to do in Drupal.

Also easy for adding / learning the testing API. Very repetitive tests for

* does the std Drupal search form element show unaltered without settings
* does the admin settings FAPI element show (redundant as the save check would also test this)
* does it save a value change correctly
* does the change change the front end search form

Only slight complication it that you need to consider users that can

* not see the form (not worth tests)
* can only access the basic search form
* can access the advanced search form

Remaining tasks

Create sub tasks for each test scenario and post the patch there.

User interface changes

None

API changes

None

Data model changes

None

Useful Resources

Resources :
https://www.drupal.org/simpletest-tutorial-drupal7 β†’

🌱 Plan
Status

Closed: outdated

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡¦Ukraine AstonVictor

    I'm closing it because the issue was created a long time ago without any further steps.

    if you still need it then raise a new one.
    thanks

Production build 0.71.5 2024