Skip to content
Snippets Groups Projects
  1. Apr 26, 2024
  2. Apr 25, 2024
  3. Apr 05, 2024
  4. Apr 25, 2024
  5. Apr 24, 2024
  6. Apr 22, 2024
  7. Apr 19, 2024
  8. Apr 09, 2024
  9. Apr 18, 2024
  10. Apr 16, 2024
  11. Apr 15, 2024
  12. Apr 11, 2024
  13. Jan 17, 2024
  14. Apr 11, 2024
  15. Apr 12, 2024
  16. Apr 11, 2024
  17. Apr 08, 2024
  18. Apr 05, 2024
  19. Apr 02, 2024
  20. Apr 04, 2024
  21. Apr 03, 2024
  22. Apr 02, 2024
  23. Jun 29, 2023
  24. Jun 22, 2023
    • Mike Hommey's avatar
      Bug 1839263 - Don't derive assertRaisesFromLine from assertRaises.... · dfa753e4
      Mike Hommey authored
      Bug 1839263 - Don't derive assertRaisesFromLine from assertRaises. r=firefox-build-system-reviewers,ahochheiden, a=test-only DONTBUILD
      
      In python 3.11 (maybe also 3.10, I haven't tested that version ; 3.9 was
      definitely different), by the time the context manager comes back in our
      assertRaisesFromLine, the traceback is not available anymore (or yet,
      I'm not entirely sure which way it does) to inspect and check the line
      numbers we want to check.
      
      And while assertRaises exposes the thrown exception in its `exception`
      attribute, it also resets the traceback associated with it, so we can't
      find it there either.
      
      So instead, we implement our own context manager for
      assertRaisesFromLine such that we can access that traceback.
      
      Differential Revision: https://phabricator.services.mozilla.com/D181425
      dfa753e4
Loading