adobe / aepsdk-core-ios

Adobe Experience Platform Mobile Core SDK in Swift
Apache License 2.0
25 stars 41 forks source link

Improve Testability in AEPCore #765

Open cdhoffmann opened 2 years ago

cdhoffmann commented 2 years ago

Currently it is very difficult to test many classes in AEPCore because we are not using the following Swift paradigms as much as we should be:

Protocol Oriented Programming: Look into using protocols more instead of concrete classes in order to allow us to create more mocks

Dependency Injection / ServiceProvider: Use service provider and dependency injection and chaining more rather than instantiating dependencies in each class. This will allow us to have more control when mocking and testing classes.

Look into other solutions to improve testability.

cdhoffmann commented 2 years ago