1. 12 Mar, 2021 1 commit
  2. 21 Oct, 2020 1 commit
  3. 03 Apr, 2019 2 commits
    • jun's avatar
      6bcc5dfd
    • Eloy Lafuente's avatar
      MDL-65204 phpunit: tweak constraint_object_is_equal_with_exceptions · 032c75ec
      Eloy Lafuente authored and jun's avatar jun committed
      In PHPUnit 7.x and above, IsEqual->value became private and, as far
      as our with exceptions class inherits from it, we cannot access to
      that anymore.
      
      So, in order to avoid that, we are overriding the constructor, capturing
      the original value for own use and forgetting.
      
      A more formal, alternative, solution would be to make our
      exceptional class to inherit from Constraint and make the
      class a pure dispatcher to different constraints, with IsEqual being
      just one of them.
      
      But we followed the easiest path here. Not ideal, but efective.
      032c75ec
  4. 03 Nov, 2017 1 commit
  5. 14 Aug, 2015 1 commit
    • Andrew Nicols's avatar
      MDL-47449 phpunit: Add comparitor for isEqual with exceptions · 504c9792
      Andrew Nicols authored
      We often do isEqual tests but where a field, may have a single exception.
      Ordinarily we can handle this easily by breaking the test down, but when
      dealing with mocked objects we can only pass an instance of a
      PHPUnit_Framework_Constraint, or a single value (which is cast to an
      instance of PHPUnit_Framework_Constraint_IsEqual).
      
      To deal with instances of time-based exception, we need to be able to
      compare simple objects and classes where one or two values may be
      different.
      504c9792