mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 06:55:59 +00:00
Remove Task.sleep from NotificationTests. (#1326)
- Add `weak` to mock variables called `delegate` - Delete `UserNotificationCenterSpy` and use `UserNotificationCenterMock` - Remove Task.sleep in favour of mock closures along with expectations/fulfillment.
This commit is contained in:
@@ -117,7 +117,7 @@ import {{ import }}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
{% macro mockOptionalVariable variable %}
|
||||
{% call accessLevel variable.readAccess %}var {% call mockedVariableName variable %}: {{ variable.typeName }}
|
||||
{% if variable.name == 'delegate' %}weak {% endif %}{% call accessLevel variable.readAccess %}var {% call mockedVariableName variable %}: {{ variable.typeName }}
|
||||
{% endmacro %}
|
||||
{% macro mockNonOptionalArrayOrDictionaryVariable variable %}
|
||||
{% call accessLevel variable.readAccess %}var {% call mockedVariableName variable %}: {{ variable.typeName }} = {% if variable.isArray %}[]{% elif variable.isDictionary %}[:]{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user