Clone of official tools
notifier/mock.py@47:21ae3e5a7128, 2021-02-04 (annotated)
- Committer:
- Anders Blomdell
- Date:
- Thu Feb 04 17:17:13 2021 +0100
- Revision:
- 47:21ae3e5a7128
- Parent:
- 43:2a7da56ebd24
Add a few normpath calls
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
theotherjimmy |
43:2a7da56ebd24 | 1 | # mbed SDK |
theotherjimmy |
43:2a7da56ebd24 | 2 | # Copyright (c) 2011-2013 ARM Limited |
theotherjimmy |
43:2a7da56ebd24 | 3 | # |
theotherjimmy |
43:2a7da56ebd24 | 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
theotherjimmy |
43:2a7da56ebd24 | 5 | # you may not use this file except in compliance with the License. |
theotherjimmy |
43:2a7da56ebd24 | 6 | # You may obtain a copy of the License at |
theotherjimmy |
43:2a7da56ebd24 | 7 | # |
theotherjimmy |
43:2a7da56ebd24 | 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
theotherjimmy |
43:2a7da56ebd24 | 9 | # |
theotherjimmy |
43:2a7da56ebd24 | 10 | # Unless required by applicable law or agreed to in writing, software |
theotherjimmy |
43:2a7da56ebd24 | 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
theotherjimmy |
43:2a7da56ebd24 | 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
theotherjimmy |
43:2a7da56ebd24 | 13 | # See the License for the specific language governing permissions and |
theotherjimmy |
43:2a7da56ebd24 | 14 | # limitations under the License. |
theotherjimmy |
43:2a7da56ebd24 | 15 | |
theotherjimmy |
43:2a7da56ebd24 | 16 | from __future__ import print_function, division, absolute_import |
theotherjimmy |
43:2a7da56ebd24 | 17 | |
theotherjimmy |
43:2a7da56ebd24 | 18 | from . import Notifier |
theotherjimmy |
43:2a7da56ebd24 | 19 | |
theotherjimmy |
43:2a7da56ebd24 | 20 | class MockNotifier(Notifier): |
theotherjimmy |
43:2a7da56ebd24 | 21 | """Collect notifications |
theotherjimmy |
43:2a7da56ebd24 | 22 | """ |
theotherjimmy |
43:2a7da56ebd24 | 23 | def __init__(self): |
theotherjimmy |
43:2a7da56ebd24 | 24 | self.messages = [] |
theotherjimmy |
43:2a7da56ebd24 | 25 | |
theotherjimmy |
43:2a7da56ebd24 | 26 | def notify(self, message): |
theotherjimmy |
43:2a7da56ebd24 | 27 | self.messages.append(message) |