mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2025-12-18 06:24:20 +01:00
Add frontend subdirectory to project
This commit is contained in:
26
frontend/test/step_request_body_test.dart
Normal file
26
frontend/test/step_request_body_test.dart
Normal file
@@ -0,0 +1,26 @@
|
||||
import 'package:auto_gpt_flutter_client/models/step_request_body.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
|
||||
void main() {
|
||||
group('StepRequestBody', () {
|
||||
test('should create StepRequestBody with correct values', () {
|
||||
final stepRequestBody = StepRequestBody(
|
||||
input: 'Execute something', additionalInput: {'key': 'value'});
|
||||
|
||||
expect(stepRequestBody.input, 'Execute something');
|
||||
expect(stepRequestBody.additionalInput, {'key': 'value'});
|
||||
});
|
||||
|
||||
test('should convert StepRequestBody to correct JSON', () {
|
||||
final stepRequestBody = StepRequestBody(
|
||||
input: 'Execute something', additionalInput: {'key': 'value'});
|
||||
|
||||
final json = stepRequestBody.toJson();
|
||||
|
||||
expect(json, {
|
||||
'input': 'Execute something',
|
||||
'additional_input': {'key': 'value'}
|
||||
});
|
||||
});
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user