Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/tizen_log/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## NEXT

* Add regression integration tests.
* Update minimum Flutter and Dart version to 3.13 and 3.1.
* Fix new lint warnings.
* Update code format.
Expand Down
58 changes: 58 additions & 0 deletions packages/tizen_log/example/integration_test/tizen_log_test.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
// Copyright 2026 Samsung Electronics Co., Ltd. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

import 'package:flutter_test/flutter_test.dart';
import 'package:integration_test/integration_test.dart';
import 'package:tizen_log/tizen_log.dart';

void main() {
IntegrationTestWidgetsFlutterBinding.ensureInitialized();

const String tag = 'TizenLogTest';

group('Log', () {
testWidgets('verbose does not throw', (WidgetTester tester) async {
expect(() => Log.verbose(tag, 'verbose message'), returnsNormally);
});

testWidgets('debug does not throw', (WidgetTester tester) async {
expect(() => Log.debug(tag, 'debug message'), returnsNormally);
});

testWidgets('info does not throw', (WidgetTester tester) async {
expect(() => Log.info(tag, 'info message'), returnsNormally);
});

testWidgets('warn does not throw', (WidgetTester tester) async {
expect(() => Log.warn(tag, 'warn message'), returnsNormally);
});

testWidgets('error does not throw', (WidgetTester tester) async {
expect(() => Log.error(tag, 'error message'), returnsNormally);
});

testWidgets('fatal does not throw', (WidgetTester tester) async {
expect(() => Log.fatal(tag, 'fatal message'), returnsNormally);
});

testWidgets('isDebugEnabled is false by default',
(WidgetTester tester) async {
expect(Log.isDebugEnabled, isFalse);
});

testWidgets('log with optional file, func, and line does not throw',
(WidgetTester tester) async {
expect(
() => Log.info(
tag,
'message with metadata',
file: 'test.dart',
func: 'main',
line: 1,
),
returnsNormally,
);
});
});
Comment thread
seungsoo47 marked this conversation as resolved.
}
10 changes: 10 additions & 0 deletions packages/tizen_log/example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,15 @@ dependencies:
tizen_log:
path: ../

dev_dependencies:
flutter_driver:
sdk: flutter
flutter_test:
sdk: flutter
integration_test:
sdk: flutter
integration_test_tizen:
path: ../../integration_test/

flutter:
uses-material-design: true
7 changes: 7 additions & 0 deletions packages/tizen_log/example/test_driver/integration_test.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

import 'package:integration_test/integration_test_driver.dart';

Future<void> main() => integrationDriver();
Loading