TF-3157 Remove unnecessary background service worker

This commit is contained in:
DatDang
2024-11-04 16:28:13 +07:00
committed by Dat H. Pham
parent 7d59982cc9
commit b76e8bb725
20 changed files with 151 additions and 447 deletions
@@ -1,44 +0,0 @@
import 'package:flutter_test/flutter_test.dart';
import 'package:tmail_ui_user/features/push_notification/data/model/web_socket_echo.dart';
void main() {
group('web socket echo test:', () {
group('isValid():', () {
test(
'should return true '
'when json is web socket echo',
() {
// arrange
final json = {
"@type": "Response",
"requestId": "R1",
"methodResponses": [["Core/echo", {}, "c0"]]
};
// act
final result = WebSocketEcho.isValid(json);
// assert
expect(result, true);
});
test(
'should return false '
'when json is not web socket echo',
() {
// arrange
final json = {
"@type": "Response",
"requestId": "R1",
"methodResponses": [["Core/not-echo", {}, "c0"]]
};
// act
final result = WebSocketEcho.isValid(json);
// assert
expect(result, false);
});
});
});
}