testParseFile method

  1. @override
dynamic testParseFile()
override

Implementation

@override
testParseFile() {
  group('Parse file:', () {
    if (simpleMessage != null) {
      test('Simple Message', () {
        expectFormatParsing(
          simpleMessage,
          format,
          messages: [messages['simpleMessage']],
        );
      });
    }
    if (messageWithMetadata != null) {
      test('Simple Message with Metadata', () {
        expectFormatParsing(
          messageWithMetadata,
          format,
          messages: [messages['messageWithMetadata']],
        );
      });
    }
    if (pluralMessage != null) {
      test('Plural Message', () {
        expectFormatParsing(
          pluralMessage,
          format,
          messages: [messages['pluralExample']],
        );
      });
    }
    if (variableMessage != null) {
      test('Message with variable', () {
        expectFormatParsing(
          variableMessage,
          format,
          messages: [messages['messageWithVariable']],
        );
      });
    }
    if (allMessages != null) {
      test('Parse file', () {
        expectFormatParsing(
          pluralMessage,
          format,
          messages: messages.values.toList(),
        );
      });
    }
  });
}