testsigma
Topics
left-mobile-bg

How to Write Test Cases for WhatsApp with Examples

May 10, 2024Ritika Kumari
right-mobile-bg
How to Write Test Cases for WhatsApp with Examples
image

Start automating your tests 10X Faster in Simple English with Testsigma

Try for free

WhatsApp is an online message application that nearly one-third of the world’s internet users operate. As of 2023, WhatsApp has almost 3 billion (Source: BacklinkO) unique users, with the expectation that this number will only increase with time. This means if WhatsApp goes down due to any issue, all the users will be affected directly. While such instances are rare, they still call for appropriate testing of the application. And every test relies on a well-defined and comprehensive list of test cases. So, here we list down the WhatsApp test cases that are essential to the proper functioning of the system.

Let’s begin!

Test Cases For WhatsApp

WhatsApp has multiple features, some of which are commonly used while others are occasionally used. The list here mentions the most regular and high-level features of the application:

Installation Testing Test Scenarios For WhatsApp

  • Verify that WhatsApp installs correctly on various mobile platforms (Android, iOS).
  • Ensure that the app requests necessary permissions (camera, contacts) during installation.
  • Check if the app specifies and utilizes storage space appropriately during installation.
  • Test upgrading from an older version, ensuring data integrity and user settings are maintained.
  • Verify the installation process on different devices.
  • Check if pausing the installation does not reset the install percentage to zero.
  • See if resuming the installation functionality is working properly.

Usability Testing Whatsapp Test Scenarios

  • Test the ease and clarity of the user registration process.
  • Verify the simplicity and accuracy of importing contacts into WhatsApp.
  • Test the ease of initiating a chat and sending messages.
  • Verify the seamless sharing of various media types (photos, videos, documents).
  • Test the user-friendliness of updating and viewing statuses.
  • Verify the simplicity of making and receiving calls, including video calls.
  • Check how the app handles and notifies users of incoming messages and calls.
  • Verify the intuitiveness of app navigation, including menus and settings.
  • Verify the responsiveness of the app to user inputs and commands.

Test Scenarios For Performance Testing

  • Simulate a large number of users to assess how WhatsApp handles concurrent connections.
  • Measure the time taken for messages to be delivered across different network conditions.
  • Test the performance of uploading and downloading media files (photos, videos).
  • Measure the responsiveness of group chats with a significant number of participants.
  • Assess the performance of voice and video calls under varying network conditions.
  • Test how well WhatsApp performs when running background processes while the app is not in use.
  • Evaluate the app’s impact on device battery life during regular usage and background processes.

Test Scenarios For Functional Testing

  • Verify the accuracy of user authentication processes, including login and logout.
  • Ensure that WhatsApp accurately syncs and updates contact information.
  • Test the core chat features, including sending and receiving messages, multimedia, and emojis.
  • Verify the creation, management, and interaction within group chats.
  • Test the initiation, reception, and termination of voice and video calls.
  • Verify that user status updates are displayed accurately to contacts.
  • Ensure that users can configure settings as intended, including privacy and security options.
  • Verify that WhatsApp functions correctly across various devices and operating system versions.

Test Scenarios For Whatsapp Group Features

WhatsApp allows users to individually text message each other and also provides a feature to create and maintain groups with multiple users. Below are test cases that are applicable to the WhatsApp group feature:

Test Cases For Admin Feature Of WhatsApp Group

  • Verify that the admin role can be assigned to a specific group member.
  • Test the functionality of admin-specific permissions, such as adding/removing members and changing group settings.
  • Check if admins receive notifications for important group activities, like member additions or removals.
  • Verify that only admins can create, add/remove, and make other users admin in the group.

Test Cases For Adding Feature Of Whatsapp Group

  • Test the ability to add new members to a group, ensuring they receive invitations.
  • Test the functionality of adding multiple members to a group simultaneously.
  • Check if new members have appropriate permissions, such as sending messages and sharing media.
  • Verify that existing members receive notifications for new member additions.

Test Cases For Delete Feature Of Whatsapp Group

  • Test the ability to delete a group, ensuring it is removed from all members’ accounts.
  • Verify that the admin can initiate group deletion process after removing all the members.
  • Check if a member can exit and delete the group for only themselves.
  • Verify that members receive notifications when removed from a group.
  • Test any recovery options available after group deletion, such as restoring archived content.

Test Case For WhatsApp Contact

Contacts are the foundation of WhatsApp. If they end up having issues, the other features of WhatsApp will break as well. These test cases should help:

  • Verify that a user can successfully add a new contact to WhatsApp.
  • Ensure that the contact information, such as name and phone number, is correctly saved.
  • Test the system’s behavior when attempting to add a contact with an existing number.
  • Verify that users can delete a contact from their WhatsApp contacts list.
  • Check if deleting a contact keeps all associated chat history intact.
  • Test the system’s response when trying to delete a non-existent contact.
  • Confirm that users can edit existing contact details (name, profile picture, etc.).
  • Ensure changes made to a contact are reflected across the application.
  • Verify that editing a contact’s number updates it in the chat history.
  • Verify that contacts are displayed with the correct name and profile picture.
  • Test the application’s behavior when a contact does not have a profile picture.
  • Test the search functionality to find contacts by name or number.
  • Verify that search results are accurate and displayed promptly.

Test Case For WhatsApp Text Field

Let’s look at some test cases for the text input field of WhatsApp:

  • Verify that users can send a text message successfully.
  • Test sending messages with different character lengths.
  • Test sending messages containing emojis and special characters.
  • Ensure that emojis are displayed correctly on both the sender’s and recipient’s devices.
  • Test text formatting options (bold, italics, underline) in the text field.
  • Verify that the formatting is applied and displayed correctly.
  • Confirm that users can edit sent text messages.
  • Test if edited messages are updated in real-time for the recipient.
  • Verify the ability to delete sent messages.
  • Test if deleted messages are removed from both the sender’s and recipient’s devices.
  • Verify that messages display accurate timestamps.
  • Test the ability to copy and paste text within the text field.
  • Confirm that pasted text retains its formatting.
  • Confirm that text messages are encrypted for privacy.

Test Case For WhatsApp Status

An interesting feature of WhatsApp, which is used by almost every user, is the Status. It is customizable and is displayed to all the contacts in your contact list. Here are the test cases for the WhatsApp Status feature:

  • Verify that users can post a new status.
  • Check if a default status is present if the user does not customize it.
  • Test different privacy settings for status (My Contacts, My Contacts Except, Only Share With).
  • Confirm that users can see who viewed their status.
  • Test the accuracy of the viewers’ list.
  • Verify that users can reply to a status.
  • Test if the reply is linked to the original status and displayed appropriately.
  • Test if users can upload multiple statuses simultaneously.
  • Verify that the order is maintained when users have multiple statuses.
  • Test the ability to edit a posted status.
  • Verify that edits are reflected for all viewers.
  • Verify that users can delete a posted status.
  • Test if deleted statuses are removed from all viewers’ lists.
  • Test the feature allowing users to mute specific contacts’ statuses.
  • Confirm that muted statuses do not appear in the status list.

Test Cases For WhatsApp Broadcast Feature

  • Verify that users can create a new broadcast list.
  • Test adding contacts to the broadcast list, ensuring accurate inclusion.
  • Test the maximum limit of recipients in a broadcast list.
  • Verify the system’s behavior when attempting to exceed the limit.
  • Confirm that users can edit the recipients in an existing broadcast list.
  • Verify that users can delete a broadcast list.
  • Test sending text messages, images, and documents via broadcast.
  • Confirm that all recipients receive the broadcasted content.
  • Verify that recipients can reply to a broadcast.
  • Test if replies are visible only to the sender.
  • Test the feature allowing users to forward broadcast messages to other contacts.

Test Cases For WhatsApp Web

You can also use WhatsApp on your laptop or PC. WhatsApp Web is a unique feature that allows you to take full advantage of the application, not just on smartphones. Test cases for this feature are listed below:

  • Verify that the QR code for WhatsApp Web is present.
  • Verify that users can successfully scan the QR code on WhatsApp Web.
  • Confirm that users can link multiple devices to the same WhatsApp account.
  • Test the synchronization of messages and settings across devices.
  • Test the security logout feature by remotely logging out of WhatsApp Web.
  • Test WhatsApp Web on different browsers (Chrome, Firefox, Safari, Edge).
  • Test the stability of the connection between the mobile app and WhatsApp Web.
  • Verify that messages are synchronized in real-time.
  • Test sending and receiving messages through WhatsApp Web.
  • Confirm that media files can be sent and received.
  • Test how notifications are handled when using WhatsApp Web.
  • Verify the behavior when the mobile device is disconnected from the internet.
  • Confirm that emoticons and stickers are displayed correctly on WhatsApp Web.
  • Test accessing and modifying account settings on WhatsApp Web.
  • Confirm that changes made on WhatsApp Web are reflected on the mobile app.

Test Cases For WhatsApp Settings

  • Verify that users can change their profile picture.
  • Test updating the user’s status.
  • Verify that the updated status is visible to selected contacts or the public, depending on privacy settings.
  • Test different account privacy settings (Last Seen, Profile Photo, About, Status).
  • Verify that users can enable and disable two-step verification.
  • Test the account deactivation feature.
  • Test the process of changing the phone number associated with the WhatsApp account.
  • Verify that users can manually initiate a chat backup.
  • Test different notification settings (message notifications, group notifications, etc.).
  • Test different security settings (fingerprint lock, face ID, etc.).
  • Test updating the WhatsApp application to the latest version.
  • Confirm that the update process is smooth and does not result in data loss.

Test Cases For Whatsapp Group Chat

The group chat on WhatsApp is a widely used feature by every user. Any user can create a group and add other users to it as per their privacy settings. A lot goes into making group chats work properly, including varying user roles. Let’s look at some test cases of the same:

  • Verify that a user can successfully create a new group.
  • Confirm that the group is immediately visible in the user’s chat list.
  • Test adding multiple members to the group.
  • Confirm that all added members receive an invitation and join successfully.
  • Test adding a group description.
  • Verify that any member of the group can change the group name and icon.
  • Verify that the group admin can remove a member from the group.
  • Confirm that the removed member no longer has access to the group.
  • Test a group member voluntarily leaving the group.
  • Confirm that the group updates for the remaining members.
  • Verify that the group creator can generate an invitation link.
  • Confirm that users joining via the link become members without further approval.
  • Test sharing images, videos, and documents within the group.
  • Verify that users can search for specific messages within the group chat.
  • Verify that the group admin can transfer admin privileges to another group member.
  • Confirm that the new admin has the necessary permissions.
  • Confirm that group information and messages are synchronized across multiple devices linked to the same account.

Test Cases for WhatsApp Profile Picture

A group has all the basic aspects of an individual chat, like a profile picture and a group description. These tests are necessary to check the profile picture feature:

  • Verify that a user can upload a new profile picture.
  • Confirm that the new picture is immediately visible to contacts.
  • Test the ability to remove the profile picture.
  • Confirm that the profile picture is replaced with the default avatar.
  • Verify that users can crop the profile picture during the upload process.
  • Test changing the profile picture frequently.
  • Confirm that the updated picture is visible to contacts without delay.

Test Cases For WhatsApp Individual Chats

Now, we come to the test scenario of checking the individual chats in WhatsApp. Every user has an individual chat box with another user that consists of a text field, video and audio call option, emojis, the other user’s display picture, and the last seen option (provided it is not hidden). The test cases in this scenario are as follows:

  • Verify that users can send text messages to individual contacts.
  • Confirm that sent messages are immediately delivered.
  • Test sharing images, videos, and documents in individual chats.
  • Verify that users can use emojis and stickers in individual chats.
  • Test sending and receiving voice messages in individual chats.
  • Verify that users can share contacts and locations in individual chats.
  • Verify that messages display accurate timestamps.
  • Confirm that read receipts (blue ticks) are displayed accurately unless stated otherwise in the privacy setting of the receiver.
  • Verify that users can react to individual chat messages.
  • Verify that users can mute notifications for a specific individual chat.
  • Test deleting individual chat messages.

Test Cases For WhatsApp Audio Calls

WhatsApp audio calls are an important feature in every individual and group chat. Below are the test cases you should include for checking audio calls on WhatsApp:

  • Verify that a user can successfully initiate an audio call.
  • Test the ability to receive an incoming audio call.
  • Verify that users can answer an incoming audio call.
  • Verify that this feature is available for both individual and group conversations.
  • Verify that users can switch from an audio call to a video call seamlessly.
  • Test muting and unmuting the microphone during an audio call.
  • Verify that users can use the speakerphone during an audio call.
  • Check that a missed call notification is sent to the receiver if they miss the call.
  • Verify that users can end an ongoing audio call.
  • Test if an audio call can be resumed seamlessly after a brief interruption (e.g., network fluctuation).
  • Verify how the application handles audio calls when it’s running in the background.

Test Cases For WhatsApp Video Calls

Similar to audio calls, video calls are yet another popular feature of WhatsApp that is used by all users. Validate the quality of it by running these test cases for WhatsApp:

  • Verify that a user can successfully initiate a video call.
  • Test the ability to receive an incoming video call.
  • Verify that users can answer an incoming video call.
  • Verify that users can switch from a video call to an audio call seamlessly.
  • Test muting and unmuting the microphone during a video call.
  • Verify that users can use the speakerphone during a video call.
  • Test switching between the front and rear cameras during a video call.
  • Verify that users can end an ongoing video call.
  • Test if a video call can be resumed seamlessly after a brief interruption (e.g., network fluctuation).
  • Verify how the application handles video calls when it’s running in the background.
  • Test if users receive proper notifications for missed video calls.

Negative Test Cases For WhatsApp

In addition to positive test scenarios, it’s crucial to examine how the application handles unexpected situations and potential vulnerabilities. Here are negative test cases for WhatsApp to simulate adverse conditions and ensure the robustness of the application:

  • Attempt to register with an invalid phone number format (e.g., missing country code).
  • Try registering with a phone number already associated with an existing WhatsApp account.
  • Enter an incorrect verification code during the registration process.
  • Try sending media files that exceed the maximum allowed size.
  • Attempt to create a group without proper authentication.
  • Perform multiple failed login attempts within a short time frame.
  • Disconnect the device from the internet during a message transmission.
  • Send media files with incorrect or unsupported formats.
  • Attempt to add more members to a group than the maximum allowed.
  • Attempt to access a user’s profile picture or status with strict privacy settings.
  • Try to reactivate a deactivated account.
  • Intentionally use an older version of the application without the latest security patches.
  • Simulate scenarios where messages are not synchronized correctly across multiple devices.

Automating a WhatsApp Test Case

You are trying to log into a WhatsApp account using an invalid phone number, let’s see the error notification message you should receive and how to run that test case using Testsigma.

  • The first step is to create a Project to upload the .apk file of WhatsApp.

Whatsapp testing

  • Next, go to Uploads to browse and upload the application file under the new Project.

Upload file

  • Now is the time to create test cases for our example. Head over to Test Cases under the same Project and create test cases. Select the application apk file during test case creation.

Create Test case

  • Upon successful creation of test cases, Record or manually select the NLPs that correspond to your test scenario. For us, it is to check if the logging in operation using an invalid number would show the right error message. Below image shows the configurations you have to select while recording steps.

Record Test steps

  • This is what you will see next after clicking on Record. The left side shows the application and the right side will list down the test steps.

Testsigma recorder

  • Now, start using the application side as you would use it on a smartphone. Every interaction will be captured in the right side box. We ran the recorder and got the below final test steps for entering an invalid phone number.

Test steps

  • Finally, verify if you receive the error message for trying to login using an invalid phone number.

For a better understanding on how to test mobile applications using Testsigma, read through our upload documentation.

Conclusion

WhatsApp is an extensively used application, used by billions of people around the world every day. Nearly 11,574 messages are exchanged on the platform every second. This figure shows how even a second of downtime can cost the company a considerable loss and inconvenience to the users. Test WhatsApp thoroughly to avoid such instances. We bring you this blog that discusses the tests to run for the application. The idea is to cover as many test cases as possible, such as application settings, about sections, profile pictures, text exchanges, chat fields, and more.

Frequently Asked Questions

How can I write a test case on WhatsApp?

Let’s take the example of verifying a text message sent. 

Description:

  • Open WhatsApp and log in.
  • Select a contact.
  • Type a text message.
  • Click the send button.
  • Confirm the message is delivered promptly.
  • Check for the correct timestamp.
  • Verify the recipient receives the message.
  • Confirm message status (single tick to double tick).
  • Ensure the message appears in the chat history.
  • Check for the appropriate sound notification.

Expected Result: The text message is sent, delivered, and received successfully with proper notifications.

What is a test case and test scenario with examples?

A test case is a detailed set of steps to be executed, inputs to be applied, and expected results for testing a particular aspect or functionality of a software application. A test scenario is a higher-level description of a particular functionality or feature to be tested. It encompasses multiple test cases and provides a broader view of the testing process. For example, a test scenario could be checking the login feature of WhatsApp, and test cases within this scenario would be verifying if an incorrect phone number prevents the user from logging in and if the correct phone number allows the user to log in.

imageimage
Subscribe to get all our latest blogs, updates delivered directly to your inbox.

RELATED BLOGS


Types of Testers: A Comprehensive Guide 
RAHUL PARWAL
AUTOMATION TESTING
Automated Test Oracles in Software Testing
KIRUTHIKA DEVARAJ
AUTOMATION TESTING
Accelq vs Provar | Which One You Should Choose?
PRIYANKA
AUTOMATION TESTING