1. 20 3月, 2019 1 次提交
    • C
      Selftests: use builtins.open for mock · c96f3c46
      Cleber Rosa 提交于
      When the recent_mock() utility was introduced, I may have missed the
      fact that it would be possible to mock builtins.open().  Or, it may
      be that was only possible in Python 3.
      
      Anyway, now that we only support Python 3, let's just mock
      builtins.open() and drop this custom decorator.
      Signed-off-by: NCleber Rosa <crosa@redhat.com>
      c96f3c46
  2. 08 3月, 2019 1 次提交
    • C
      Drop Python 2 · a90c24c6
      Cleber Rosa 提交于
      And the compatiblity helper six.  With Python 2 gone, a number of
      package changes are also introduced, so that the packages are always
      named python3-<suffix>.
      
      Also, because it would be confusing not having an "avocado" script,
      and to conform with the system wide change introduced by distros that
      now offer Python 3 by default, the scripts are no longer called
      avocado-3 (or avocado-3.x), but simply "avocado".
      Signed-off-by: NCleber Rosa <crosa@redhat.com>
      a90c24c6
  3. 15 12月, 2018 1 次提交
    • L
      selftests: Setup avocado logging streams in unit tests · ea258cdd
      Lukáš Doktor 提交于
      Avocado requires the logging streams to be set before some calls. Most
      critical ones are 'avocado.Test' related ones as without initialization
      the:
      
          No handlers could be found for logger...
      
      messages can cause infinite recursion. Anyway there are other places
      where avocado loggers are called so let's set it on (hopefully) all
      places (we have to treat some utils as well as for backward
      compatibility reasons these utils use avocado loggers directly).
      
      Note in functional tests this is not required as Avocado always setup
      logging streams prior using those utils (otherwise the failure would be
      a real bug).
      Signed-off-by: NLukáš Doktor <ldoktor@redhat.com>
      ea258cdd
  4. 06 12月, 2018 3 次提交
  5. 18 9月, 2018 1 次提交
  6. 03 8月, 2018 1 次提交
  7. 03 9月, 2015 1 次提交
    • C
      Selftests: move to adhere to unittest discover default pattern · 24d87eb4
      Cleber Rosa 提交于
      To be honest, our test code could still be kept in the same directories and
      have the same names. But I think we can improve two things here:
      
      1) Flatten a little bit the directory structure of selftests. Two path
      components are being dropped here: "all" and "avocado". So that
      "selftests/all/functional/avocado" becomes simply
      "selftests/functional".
      
      2) File names match what is, by default, recognized by unittest (the
      Standard Library module) based discovery of tests. That means that
      doc_build_test.py becomes test_doc_build.py. Not a big deal IMHO.
      Signed-off-by: NCleber Rosa <crosa@redhat.com>
      24d87eb4
  8. 03 4月, 2014 1 次提交
  9. 06 3月, 2014 2 次提交