Two Ways to Unit Test Notification Center in Swift

This page summarizes the projects mentioned and recommended in the original post on reddit.com/r/iOSProgramming

Our great sponsors
  • Appwrite - The Open Source Firebase alternative introduces iOS support
  • Scout APM - Less time debugging, more time building
  • SonarLint - Clean code begins in your IDE with SonarLint
  • TypedNotificationCenter

    Typed version of Apple's NotificationCenter to avoid forgetting setting parameters in the userInfo dictionary and needing to handle not having those parameters.

    You shouldn't really be using NotificationCenter, it doesn't have typesafe API and has bad performance. If you really like the API, I made a framework that provides the same API but you can associate types with the sender/payload: https://github.com/Cyberbeni/TypedNotificationCenter

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts