Skip to content

Commit

Permalink
feat: add event bus visible for testing properties
Browse files Browse the repository at this point in the history
  • Loading branch information
luisburgos committed Aug 5, 2022
1 parent f6edc02 commit 214867a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions lib/infra/typed_event_bus.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
import 'dart:async';

import 'package:buzz/buzz.dart';
import 'package:buzz/utils/subtype_checker.dart';
import 'package:event_bus/event_bus.dart';
import 'package:flutter/foundation.dart';

abstract class TypedEventBus<T> {
@visibleForTesting
StreamController get eventBusStreamController => _eventBus.streamController;

@visibleForTesting
Stream get eventBusStream => eventBusStreamController.stream;

final _eventBus = EventBus();

bool isTypeSupported<X>() {
Expand Down

0 comments on commit 214867a

Please sign in to comment.