OndrejKunc / flutter_dynamic_forms

A collection of flutter and dart libraries allowing you to consume complex external forms at runtime.
MIT License
203 stars 59 forks source link

expression_language package mods for updated rational and other deps #114

Open timmaffett opened 1 year ago

timmaffett commented 1 year ago

This pull primarily modifies the expression_language package to work with the current versions of the dependencies. It primarily modifies decimal.dart to work with current rational package. It does add a new passed_in_old_version.feature file which contains one of the previous tests which no longer passes. I believe this must be because of a change within the petite_parser package. I was able to modify this test within the existing expressions_can_solve.feature file in line 652 by adding parentheses around the ! subject.

With the addition of the parentheses all tests pass once again with this version. It was not a requirement for me to have the previous test pass so I did not get to the bottom of the required fixes to the gramar to make the previous test pass again with the new petite_parser.

TLDR:

When expression "!@testElement.nullableBoolValue!" is evaluated became When expression "!(@testElement.nullableBoolValue!)" is evaluated

The contents of the new passed_in_old_version.feature file is included below to highlight the need to possibly fix the gramar for the new petite_parser package to this test passes once again.

passed_in_old_version.feature file which contains test which passes in previous version:

Feature: Expression
  Tests an expression

  Scenario: Negate Nullable bool
    Given form element is provided
    When expression "!@testElement.nullableBoolValue!" is evaluated
    Then bool expression result is "false"