Enhancing App Automation by Implementing Push Notification Automation at Halodoc

automation Sep 27, 2024

At Halodoc, ensuring efficient and thorough testing of our mobile applications is paramount. Push notifications are a critical feature we test extensively, as they play a vital role in maintaining user engagement and ensuring timely communication. Notifications inform doctors when they receive patient requests or notify patients of follow-ups from their doctors. Given their importance, automating the testing process of these notifications is essential. Manual testing can be time-consuming and prone to human error, potentially leading to oversights that affect user experience. To streamline this process, we automated push notification testing in our Android app using Appium.

In this blog, we will explore how we have integrated push notification automation into our Android app using Appium and XCUITest using in iOS. We will discuss the challenges we faced, the solutions we implemented, and the benefits we have observed.

What are Push Notification?

Push notifications are messages that pop up on a mobile device, playing a crucial role in Halodoc's operations by facilitating smooth communication, enhancing user experience, and ensuring timely delivery of health services. Here's a deeper dive into their significance:

Key Examples of Push Notifications in Halodoc:

Medicine order status:

  • Order Booked: Confirms the order has been successfully placed.
  • Order On the Way: Notifies the user that their order is on its way.
  • Order Completed: Confirms that the order process has been completed.
  • Order Canceled: Informs the user about order cancellation.
  • Order Rescheduled: Notifies changes in the order delivery schedule.

Consultation Notifications:

  • Consultation Started: Informs the user that their consultation has begun.
  • Consultation Scheduled: Alerts the user about their scheduled consultation.

Reminders and Alerts:

  • Medicine Reminder: Reminds the user to take their medication on time.

Challenges Faced in Testing Push Notifications Manually

 Testing push notifications manually presents several significant challenges:

  • Time-Consuming: Manually verifying push notifications is labor-intensive and delays the release cycle.
  • Inconsistent Results: Manual checks can lead to inconsistent results due to varying conditions and human judgment.
  • Dynamic Content: Ensuring the accuracy of user-specific data in notifications is difficult and time-consuming to verify manually.
  • Multilingual Support: Verifying notifications in multiple languages adds complexity and increases the likelihood of errors.
  • Cross Platform Testing: Testing push notifications manually across iOS and Android presents challenges such as varying platform behaviors, device fragmentation, and differing notification handling, making it impractical and error-prone. Ensuring consistent behaviour and user experience across platforms requires extensive and meticulous manual testing.

Benefits of Automating Push Notification Testing

  • Automating push notification testing on Android and iOS streamlined our workflows, saving considerable time and effort previously spent on manual verification.
  • This automation ensured consistent and thorough testing across various Android and iOS versions and devices, significantly enhancing test accuracy and reliability by minimising human errors.
  • It also improved our ability to validate dynamic content and multilingual support effectively, contributing to a more stable and reliable app before deployment.
  • Automated testing enabled prompt identification and resolution of notification handling issues, ultimately leading to a smoother user experience post-deployment.

Why Should We Automate Push Notifications in apps?

Automating push notifications in apps offers numerous benefits, particularly in terms of efficiency and reliability. Manual testing of push notifications is highly time-consuming, as it requires testers to repeatedly check each notification under various conditions. This process can significantly delay the release cycle, especially when updates or new features necessitate frequent testing.

By implementing automation using app, we can save a considerable amount of time. Automated tests can run continuously and simultaneously across multiple devices and scenarios without the need for human intervention. This not only speeds up the testing process but also allows our team to focus on more critical and complex testing tasks.

For detailed processes on how to integrate these functionalities, check out these blogs.

1. Android

Enhancing Android App Automation by Implementing Push Notification Automation at Halodoc.
At Halodoc, ensuring efficient and thorough testing of our mobile applicationsis paramount. Push notifications are a critical feature we test extensively, asthey play a vital role in maintaining user engagement and ensuring timelycommunication. Notifications inform doctors when they receive patie…

2. iOS

Enhancing iOS App Automation by Implementing Push Notification Automation at Halodoc.
At Halodoc, ensuring efficient and thorough testing of our mobile applicationsis paramount. One critical feature we test extensively is push notifications,which play a vital role in maintaining user engagement and ensuring timelycommunication with our users. For instance, notifications might noti…

Benefits Achieved

Implementing automated push notification testing with Appium for Android and XCUITest for iOS has brought several significant benefits to our testing process:

  1. Time Savings: By automating the testing of push notifications, we have drastically reduced the time required for regression testing. What previously took several hours of manual testing can now be executed in a fraction of the time. This has led to an estimated savings of 1 man-hours per release cycle. With automated tests running overnight, our team is freed up to focus on more complex tasks and innovations.
  2. Increased Test Coverage: Automation has allowed us to run a larger number of test scenarios compared to manual testing. This increased coverage ensures that various push notification scenarios are thoroughly tested across different devices and operating systems, reducing the likelihood of issues slipping through.
  3. Consistency and Reliability: Automated tests provide consistent execution every time they run, minimizing human error. This reliability has improved our confidence in the results and reduced the need for re-testing due to inconsistencies.
  4. Early Detection of Issues: Automated testing enables continuous integration and frequent testing, which leads to the early detection of issues. By catching problems earlier in the development cycle, we can address them promptly and reduce the cost of fixing bugs.
  5. Scalability: As our application grows and the number of test cases increases, automation scales effortlessly. We can easily add new test cases or modify existing ones without a significant increase in testing time or effort.

Conclusion

Automating push notification testing with Appium and XCUITest has revolutionised our testing process, addressing significant challenges while yielding impressive results. Initially, the need to verify each notification individually and interact with them manually posed challenges. However, automation streamlined these tasks, saving substantial manual effort and ensuring rigorous testing across diverse Android and iOS environments.

As a result, our testing now boasts enhanced accuracy and reliability. By automating notification handling, we effectively validated dynamic content and multilingual support, crucial for maintaining a seamless user experience. Overall, automating push notification testing with Appium and XCUITest has fortified our commitment to delivering robust, high-quality applications that meet the expectations of our users consistently.

Join Us

Scalability, reliability, and maintainability are the three pillars that govern what we build at Halodoc Tech. We are actively looking for engineers at all levels and if solving hard problems with challenging requirements is your forte, please reach out to us with your resume at careers.india@halodoc.com.

About Halodoc

Halodoc is the number one all-around healthcare application in Indonesia. Our mission is to simplify and bring quality healthcare across Indonesia, from Sabang to Merauke. We connect 20,000+ doctors with patients in need through our Tele-consultation service. We partner with 3500+ pharmacies in 100+ cities to bring medicine to your doorstep. We've also partnered with Indonesia's largest lab provider to provide lab home services, and to top it off, we have recently launched a premium appointment service that partners with 500+ hospitals that allow patients to book a doctor appointment inside our application. We are extremely fortunate to be trusted by our investors, such as the Bill & Melinda Gates Foundation, Singtel, UOB Ventures, Allianz, GoJek, Astra, Temasek, and many more. We recently closed our Series D round and in total have raised around USD 100+ million for our mission. Our team works tirelessly to make sure that we create the best healthcare solution personalized for all of our patient's needs, and are continuously on a path to simplify healthcare for Indonesia.

Yogeshwari G N

Software Development Engineer In Test