Skip to content

Testing Instructions for Critical Flow

Ankit K Gupta edited this page Dec 20, 2023 · 9 revisions

Please follow the below instructions to execute/run cases mentioned in the critical flow.

Admin can activate the plugin without error

The plugin should be installed and activated without any error or trouble.

Steps:

  1. Download the Plugin zip file.
  2. Install the plugin zip in the Plugin Uploader screen of the site.

Expected Result-

The plugin should be installed without any error.


Plugin should show an error message when activating the un-supported PHP version.

Steps:

  1. Downgrade PHP version if using =< PHP 7.4
  2. Activate the plugin

Expected Result-

  1. Plugin should show a warning notice on activation.
  2. Plugin setup/setting buttons should not appear.

Screenshot 2023-12-18 at 8 11 55 PM


Plugin Activation Banner Display

Steps:

  1. Navigate to the WordPress admin dashboard.
  2. Go to the "Plugins" section.
  3. Locate and activate the ClassifAI plugin.

Expected Result-

Upon successful activation, a banner should be displayed in the header area.

  1. The banner text should have: "Congratulations, the ClassifAI plugin is now activated".
  2. The banner should include a button labelled 'Start Setup'.



NLU - Classify Content Setting Check - Admin Screen Settings

The objective of this test case is to ensure the functionality and configuration of the NLU (Natural Language Understanding) - Classify Content settings on the admin screen.

Steps:

  1. Navigate to WP Dashboard > Tools > ClassifAI > Language Processing > IBM Watson > Natural Language Understanding Screen.
  2. Check the setting 'Classify Content'.
  3. Scroll to the bottom of the setting page and enable the setting 'Post Types to Classify'.
  4. Select 'Post' and 'Pages'.
  5. Enable checkbox for 'Category' and select 'Watson Category' from the dropdown.
  6. Save the setting by clicking the 'Save Changes' button.

Expected Result:

  1. The 'Classify Content' setting should be visible.
  2. The 'Post Types to Classify' setting should be present at the bottom of the page.
  3. 'Post' and 'Pages' should be selectable options for content classification.
  4. After saving changes, there should be a success message indicating that the changes were saved successfully.
  5. The settings should persist after saving, and the selected post types should remain enabled.

NLU - Classify Content Setting Check - Setting Output on Post/Page Screen

The objective of this test case is to ensure the functionality and configuration of the NLU (Natural Language Understanding) - Classify Content settings on the page and post screen.

Steps:

  1. Navigate to WP Dashboard > Tools > ClassifAI > Language Processing > IBM Watson > Natural Language Understanding Screen.
  2. Check the setting 'Classify Content'.
  3. Scroll to the bottom of the setting page and enable the setting 'Post Types to Classify'.
  4. Select 'Post' and 'Pages'.
  5. Enable checkbox for 'Category' and select 'Watson Category' from the dropdown.
  6. Save the setting by clicking the 'Save Changes' button.

Expected Result:

  1. Navigate to WP Dashboard > Pages or Posts
  2. Open any Post/Page or create a new Post/Page
  3. Look at Post/Page editor right-hand sidebar section
  4. 'Watson Categories' section should appear.

NLU - Verify Setting 'Enable Role-Based Access'

Steps:

  1. Navigate to WP Dashboard > Tools > ClassifAI > Language Processing > IBM Watson > Natural Language Understanding Screen.
  2. Check the setting 'Enable Role-Based Access'.
  3. The user role list should open, displaying all WP roles.
  4. Enable a user role (for example editor) to use the Classify setting.
  5. Save the setting.

Expected Result:

After saving the setting, only the allowed user role (for example: editor)should have access to the Classify setting on the page/post edit screen.


NLU - Verify Setting 'Enable Role-Based Access' for User Side

Steps:

  1. Follow the steps from the previous test case: "NLU - Verify Setting 'Enable Role-Based Access.'"
  2. Create a new user with the editor user role.
  3. Create or edit a page/post using the newly created user.
  4. Observe the ClassifAI section in the sidebar.

Expected Result:

A user with the editor role should be able to see the ClassifAI settings in the sidebar when creating or editing a page/post.


Negative Test Case: NLU - Verify Setting 'Enable Role-Based Access' from User Side

Steps:

  1. Follow the steps from the previous test case: "NLU - Verify Setting 'Enable Role-Based Access.'"
  2. 'Enable Role-Based Access' setting is unchecked for the editor role.
  3. Create a new user with the editor user role.
  4. Create or edit a page/post using the newly created user.
  5. Observe the ClassifAI section in the sidebar.

Expected Result:

A user with the editor role should not be able to see the ClassifAI settings in the sidebar when creating or editing a page/post since the editor role is not checked in the 'Enable Role-Based Access' setting.


NLU - Verify Setting "Enable User-Based Access" for Classifying Content on Page/Posts

Steps:

  1. Navigate to WP Dashboard > Tools > ClassifAI > Language Processing > IBM Watson > Natural Language Understanding Screen.
  2. Check the setting "Enable User-Based Access."
  3. Option to select users will be displayed.
  4. Select a user to enable for Classifying Content.
  5. Save the setting.
  6. Log in with the selected user account.
  7. Create or edit a page/post.
  8. Observe the ClassifAI section in the sidebar.

Expected Result:

After saving the setting and logging in with the selected user account, the user should be able to see the ClassifAI settings in the sidebar when creating or editing a page/post.


NLU - Verify Setting "Enable User-Based Opt-Out" for opting out Classifying feature.

Steps:

  1. Navigate to WP Dashboard > Tools > ClassifAI > Language Processing > IBM Watson > Natural Language Understanding Screen.
  2. Check the setting "Enable User-Based Opt-Out."
  3. Save the setting.
  4. Log in with any other user account.
  5. Go to the user profile page for the selected user.
  6. Look for the option to opt-out from Classifying Content.

Expected Result:

  1. After saving the setting and logging in with the selected user account, the user should be able to see an option to opt-out from Classifying Content on their user profile page.
  2. After enabling the setting 'Opt out of using the classify content feature.' user should not see the ClassifAI features on edit/new post/page.

Clone this wiki locally