FIRTestComponents.h 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. // Copyright 2018 Google
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. #import <Foundation/Foundation.h>
  15. #import <FirebaseCore/FIRComponent.h>
  16. #import <FirebaseCore/FIRComponentContainer.h>
  17. #import <FirebaseCore/FIRLibrary.h>
  18. @protocol FIRComponentRegistrant;
  19. #pragma mark - Standard Component
  20. /// A test protocol to be used for container testing.
  21. @protocol FIRTestProtocol
  22. - (void)doSomething;
  23. @end
  24. /// A test class that is a component registrant.
  25. @interface FIRTestClass : NSObject <FIRTestProtocol, FIRComponentLifecycleMaintainer, FIRLibrary>
  26. @end
  27. /// A test class that is a component registrant, a duplicate of FIRTestClass.
  28. @interface FIRTestClassDuplicate
  29. : NSObject <FIRTestProtocol, FIRComponentLifecycleMaintainer, FIRLibrary>
  30. @end
  31. #pragma mark - Eager Component
  32. /// A test protocol to be used for container testing.
  33. @protocol FIRTestProtocolEagerCached
  34. - (void)doSomethingFaster;
  35. @end
  36. /// A test class that is a component registrant that provides a component requiring eager
  37. /// instantiation, and is cached for easier validation that it was instantiated.
  38. @interface FIRTestClassEagerCached
  39. : NSObject <FIRTestProtocol, FIRComponentLifecycleMaintainer, FIRLibrary>
  40. @end
  41. #pragma mark - Cached Component
  42. /// A test protocol to be used for container testing.
  43. @protocol FIRTestProtocolCached
  44. @end
  45. /// A test class that is a component registrant that provides a component that requests to be
  46. /// cached.
  47. @interface FIRTestClassCached
  48. : NSObject <FIRTestProtocol, FIRComponentLifecycleMaintainer, FIRLibrary>
  49. @end