Skip to content
Snippets Groups Projects
  1. Apr 24, 2019
  2. Mar 01, 2019
  3. Jan 31, 2019
    • Akihiro Motoki's avatar
      UT: Run test_plugins as separate process · a69ba853
      Akihiro Motoki authored
      This commit changes to run test_plugins in a separate process.
      
      test_plugins touches urlpatterns and Site registry during setUp(),
      but the cleanup process in tearDown does not recover urlpatterns correctly.
      After tests under test_plugins run, the urlpatterns continues to have
      entries of test panels and this leads to NoReverseMatch error when
      rendering other panels after that.
      
      I investigated details in setUp/tearDown of PluginTestCase but failed
      to find a good solution to recover urlpatterns and Horizon Site registry.
      As a workaround, runnig test_plugins in a separate process can avoid
      the issue.
      
      Closes-Bug: #1809983
      Change-Id: I848f6b341b3f93ed055955b2b12d2497811edc5a
      a69ba853
  4. Dec 22, 2018
  5. Jun 08, 2018
    • Ivan Kolodyazhny's avatar
      Use default Django test runner instead of nose · 1f80d944
      Ivan Kolodyazhny authored
      Nose has been in maintenance mode for the past several years. It has
      issue with exit code [1] which leads to false positive results for our
      seleniun-headless job.
      
      This patch changes test runner for Horizon tests and does the following
      things:
      
      * Django test runner  executes test in a different order than Nose does.
        That's why we've got an issue with side-effect in
        horizon.tests.unit.tables.test_tables.MyToggleAction class. This patch
        adds workaround to it.
      * Rename filename of test files to names starting with 'test_'
        so that the django test runner can find tests expectedly.
      * '--with-html-output' option is temporary dropped and will be added in
        a following patch.
      * Integraion tests is marked via django.test.tag mechanism which is
        introduced in Django 1.10
      * 'selenium-headless' is broken now because we don't have geckodriver on
        gates, this patch makes it non-voting.
      * 'tox -e cover' is fixed
      * Remove @memorized decorator from
        dashboards.project.images.images.tables.filter_tenant_ids function.
      
      [1] https://github.com/nose-devs/nose/issues/984
      
      Depends-On: https://review.openstack.org/572095
      Depends-On: https://review.openstack.org/572124
      Depends-On: https://review.openstack.org/572390
      Depends-On: https://review.openstack.org/572391
      
      Related blueprint: improve-horizon-testing
      Change-Id: I7fb2fd7dd40f301ea822154b9809a9a07610c507
      1f80d944
  6. Apr 05, 2018
    • Ivan Kolodyazhny's avatar
      Make tests output more verbose · 0c39d76e
      Ivan Kolodyazhny authored
      Added '--verbosity 2' to print list of executed and skipped tests to the
      console.
      
      Related blueprint: improve-horizon-testing
      Change-Id: Ibdc4016bb1f8b7145a78b0f0bfc693741b6a123e
      0c39d76e
  7. Jan 24, 2018
    • Shu Muto's avatar
      Ignore node_modules from test target · e5986957
      Shu Muto authored
      Files in node_modules directory are not target for test.
      So we should ignore them.
      
      Change-Id: I3b259c7df21660e61fcb55633c82bdd83d791a3d
      e5986957
  8. Dec 27, 2017
  9. Dec 19, 2017
  10. Dec 05, 2017
    • Akihiro Motoki's avatar
      Drop Heat related code from horizon · eac3e703
      Akihiro Motoki authored
      Orchestration tab in the admin info panel needs a discussion.
      It seems not to be covered by heat-dashboard yet.
      
      blueprint heat-dashboard-split-out
      
      Change-Id: I56e6edb1f2ac72e2f42d0e9f3291308e67f24cad
      eac3e703
  11. Sep 27, 2017
    • Rob Cresswell's avatar
      Add Django OpenStack Auth to Horizon · e3e5812b
      Rob Cresswell authored
      Moves Django OpenStack Auth content to Horizon, since they are so
      tightly coupled. This cleans up the development workflow and should
      make keystone / auth related contributions easier.
      
      Implements: blueprint merge-openstack-auth
      Change-Id: Ia1cdc47bad1ca6e633073a9f9445b0c7f70d05bc
      e3e5812b
  12. Aug 15, 2017
  13. Jul 28, 2017
    • adrian-turjak's avatar
      Ensure tox registers failures properly · 280848c5
      adrian-turjak authored
      Tox runs tests via unit_tests.sh which when not
      running a test subset will mean tox only checks for
      the final exit code. This means horizon test failues
      will not be seen by tox unless openstack_dashboard
      tests also fail.
      
      This change forces an exit code which !=0 if either
      test run fails.
      
      Change-Id: I8fbcb834d9817e7eea1b2c39fc4caab6004b981b
      280848c5
  14. Mar 17, 2017
    • Akihiro Motoki's avatar
      hacking: noqa cleanup in horizon · 61091388
      Akihiro Motoki authored
      attribute-level imports are not checked by hacking module now.
      most noqa is used to disable warnings on attribute-level imports.
      This commit drops noqa for this purpose.
      
      After this, there are 8 noqa under horizon/ :)
      
      In addition to this, the following changes are made.
      
      horizon/exceptions.py: The following imports are dropped.
      They are not used anywhere.
        from django.http import HttpRequest
        from django.views.debug import CLEANSED_SUBSTITUTE
      
      horizon/forms/__init__.py:
      Some entries were missing in __all__. They are added.
      
      Change-Id: I33b504ef6c396f0675e8a340867e2ca59c77c684
      61091388
  15. Nov 30, 2016
    • Rob Cresswell's avatar
      Refactor tox & update docs · 36d1d1ac
      Rob Cresswell authored
      - Updated tox envlist, so just running `tox` from the CLI will now run all
      voting gate tests
      
      - Reduce duplicated definitions and commands
      
      - Remove any reliance on run_tests within tox
      
      - Removes all doc references to run_tests.sh, and replaces them
      with their tox equivalent. Where necessary, language around the tox
      commands has been altered or extended so that it makes sense and is
      consistent with other parts of the docs. Also adds a new "Test Environment"
      list to the docs, so that newcomers do not have to piece together CLI
      commands and their cryptic extensions from tox.ini
      
      - Move the inline shell scripting to its own file. Also fixes a bug when
      passing args, since the logic assumed you were attempting a subset test
      run (try `tox -e py27 -- --pdb` on master to compare)
      
      - Moved translation tooling from run_tests to manage.py, w/ help text
      and arg restrictions. This is much more flexible so that plugins can use
      it without having to copy commands, but still defaults to exactly the
      same parameters/behaviour from run_tests. Docs updated appropriately.
      
      - Removed npm/karma strange reliance on either .venv or tox/py27. Now
      it only uses tox/npm.
      
      Change-Id: I883f885bd424955d39ddcfde5ba396a88cfc041e
      Implements: blueprint enhance-tox
      Closes-Bug: 1638672
      36d1d1ac
  16. Nov 28, 2016
    • Tony Breeds's avatar
      Add constraints support to run_tests.sh · a909ed26
      Tony Breeds authored
      Currently developers need to manually build a constratined venv if they
      want to  match the versions that are tested in the gate.  This change
      adds logic to run_tests.sh and install_venv*.py to default to the same
      constraints file used in the gate.
      
      With constraints enabled the 'churn' in the environment should be
      minimised so remove the developer optimisation for detecting when
      packaged versions change and always just install/update.  This has the
      down side of making the script preamble slightly longer but we always
      print_help() so I don't think it'll be terribly inconvenient.
      
      Change-Id: I9bf85adb5aa2c85d8c0f0f22ac9efe5cac3646c0
      Closes-Bug: 1644697
      a909ed26
  17. Sep 20, 2016
    • Timur Sufiev's avatar
      Fix the collection of integration tests artifacts · 2fec0a1a
      Timur Sufiev authored
      Don't rely on a particular workspace name, as it changes when job's
      name changes.
      
      Depends-On: I28d84235fb51a49492ed9c96794ba74f317f66b6
      Change-Id: I63e45ee89711b429d0d878303aefeec4b159125a
      Closes-Bug: #1625253
      2fec0a1a
  18. Aug 11, 2016
    • Matt Borland's avatar
      Pre-test hook for integration tests/deprecated · 75427ad7
      Matt Borland authored
      We want to allow for integration tests to test deprecated panels.  This
      means that we need to override the configurations provided by the panels
      and force a 'legacy' setting.
      
      On the Infra side, we need to pass in an environment variable that tells this
      override to be enabled.
      
      Depends-On: I20232ef16ae60a7151e267b506af471ebfed2f7f
      Change-Id: If5a3e273098aa726e12f9076c0273a5afaf233d2
      Partially-Implements: blueprint test-deprecated-features
      75427ad7
  19. Jun 09, 2016
  20. Jun 07, 2016
  21. Apr 25, 2016
  22. Apr 22, 2016
    • Sergei Chipiga's avatar
      Fix pre_test_hook fail and sidebar menu fail · 79fcc654
      Sergei Chipiga authored
      It fixes two small but important bugs:
      - remove apache restart, because it fails pre_test_hook, which fails
        test build (the latter implication was introduced recently in a
        devstack-gate scripts);
      - fix sidebar menu item click before prev item was collapsed, because
        in this case menu item won't be expanded (supposedly a result of
        recent update of one of XStatic dependencies).
      
      Change-Id: If463c4c8b16b54f033e2a2ee33ba995ca7844f2b
      Closes-Bug: #1573726
      79fcc654
  23. Apr 20, 2016
    • TatyanaGladysheva's avatar
      Added test for check stacks creation and deletion functionality · eda58de3
      TatyanaGladysheva authored
      Test checks that create/delete stacks actions are executed without
      errors under admin user.
      Stacks page object was defined similar to other pages.
      
      Few other modifications I've made:
      * horizon.conf - service_available section with new heat option
      * stack template is added as separate file
      
      Depends-On: I1f5dc1220aee39103289a579583095346cce0354
      Implements blueprint: horizon-integration-tests-coverage
      Change-Id: Ibc549f9ae4eac17d8e92d65afe1c5cee9be6e72e
      eda58de3
  24. Mar 18, 2016
  25. Mar 03, 2016
    • Rob Cresswell's avatar
      Enable Angular Launch Instance by default · 2843ce3c
      Rob Cresswell authored
      
      This patch enables the Angular Launch Instance workflow by default. The
      toggle has been maintained for those running the Python workflow, and
      also for the integration tests to run against both simultaneously.
      
      Keep integration tests running for a legacy Launch Instance workflow
      by means of a separate local_settings.d code snippet activated before
      starting the tests.
      
      Co-Authored-By: default avatarTimur Sufiev <tsufiev@mirantis.com>
      Change-Id: Id0c57b33df46397711e32092cec6cc5268841779
      Implements: blueprint enable-angular-launch-instance
      2843ce3c
  26. Jan 22, 2016
  27. Jan 11, 2016
  28. Oct 29, 2015
  29. Jul 02, 2015
    • Neill Cox's avatar
      Angular translation via babel (singular only) · 9b36822f
      Neill Cox authored
      An approach to i18n for Angular HTML templates using babel. This patch
      allows only singular translation. Plurals and context will be
      addressed in subsequent patches.
      
      Based on Thai Tran's work at https://review.openstack.org/#/c/187321
      
      This patch implements a custom extractor in
      horizon/utils/babel_extract_angular.py. pybabel really wants this to be
      a package installed into site-packages. I have not done this so as to
      avoid introducing a dependency on another change to global requirements
      just yet. I will upload a package to pypi in parallel so that we can
      start using it in the future.
      
      For now, I have had to modify tools/with_venv.sh to add horizon to the
      PYTHONPATH. This is less than ideal but seemed to be the least worst
      option.
      
      Steps to verify that it works:
      1. Create a new html file in horizon/static or openstack_dashboard/static
      2. Add something like <div translate>hello world!</div> to the html
         To test interpolation add something like:
           <div translate>hello {$name$}!</div>
      3. Run ./run_tests.sh --makemessages
      4. Inspect your djangojs.po file, it should be there.
      
      The following steps are optional:
      5. Run ./run_tests.sh --pseudo de
      6. Run ./run_tests.sh --compilemessages
      7. Go to http://localhost:8000/settings
      8. Change Language to Deutsch
      9. Go to http://localhost:8000/i18n/js/horizon+openstack_dashboard
      10. Your translated text should be there as well.
      
      Note: There are now unit tests as well.
      
      Partially-Implements: blueprint angular-translate-makemessages
      Depends on: If4352aba01ce0ca6337f590c0689d8fe9f0867c8
      
      Change-Id: I26d4fef8646d5f038918cd3376dbbdbef37eb603
      9b36822f
  30. Jan 27, 2015
    • David Lyle's avatar
      Adding review clean up script · 2037fdab
      David Lyle authored
      This is modeled after the nova script to do the same thing.
      
      Removes reviews over 4 weeks old that are either failing Jenkins
      or have a -2.
      
      Change-Id: I636738c873c1b64ba1aa24fd7643b2fac9b1975b
      2037fdab
  31. Jan 20, 2015
    • Doug Fish's avatar
      Pseudo translation tool · faae8b86
      Doug Fish authored
      A tool to allow pseudo translations to be created in order to identify
      potential translation problems. To use the tool:
      Make sure your English file is up to date:
      ./run_tests.sh --makemessages
      
      Run the pseudo tool to create pseudo translations:
      ./run_tests.sh --pseudo de
      
      Compile the catalog:
      ./run_tests.sh --compilemessages
      
      Run your dev server. Log in and change to the language you pseudo translated.
      It should look weird. More specifically, every translatable string is going
      to start and end with a bracket and they are going to have some added
      characters. For example, "Log In" will become "[~Log In~您好яшçあ]"
      This is useful because you can inspect for the following:
      - If you see a string in English it's not translatable. Should it be?
      - If you see brackets next to each other that might be concatenation.
      - If there is unexpected wrapping/truncation there might not be enough
        space for translations
      - If you see a string in the proper translated language, it comes from an
        external source. (That's not bad, just sometimes useful to know)
      - If you get new crashes, there is probably a bug. :-)
      
      Implements blueprint: pseudo-translation-tool
      
      Change-Id: If97754c2d4234b12b3d73616ff60527f6ad82d55
      faae8b86
  32. Jul 08, 2014
    • James E. Blair's avatar
      Remove requirements style check · 5b302877
      James E. Blair authored
      This is incorrect and should never have been added.  The order of
      lines in requirements files affects the pip dependency resolver.
      Therefore, while it's nice to add new packages in alphabetical
      order, it must not be required.
      
      Move pbr to the top of the list as it should always be installed
      first.  Move hacking to the top of the test-requires list.
      
      Change-Id: I81f7e75b77baccd12d9660dc009f30f2f2c891bc
      5b302877
  33. Apr 05, 2014
    • Akihiro Motoki's avatar
      Sync latest Oslo · 21b7822f
      Akihiro Motoki authored
      Sync from oslo-incubator commit 46f2b697b6aacc674bc040a8751997ed70490d1a
      
      Major changes of the import are related to update policy module:
      0da5de6b54 Allow policy.json resource vs constant check
      5d1f15a778 Documenting policy.json syntax
      33533b0d97 Keystone user can't perform revoke_token
      
      Most changes are style-related topics:
      * Improve Python3 compatibility
      * Remove vim modelines
      * Support Per-log-level logging translations
      
      Closes-Bug: #1296337
      Change-Id: I09f61b10b1b36015d248de25c5c6ed994717a565
      21b7822f
  34. Mar 03, 2014
    • ChenZheng's avatar
      Sort requirement files in alphabetical order · 4d6238ce
      ChenZheng authored
      This makes code more readable, and can check whether specific library
      in the requirement files easily. We enforce the check in pep8, We also
      add the tools for checking requirements.txt and test_requirements.txt.
      
      Change-Id: Ia0a24553b7a5204faf6413c17dae6ba6aae2b5e8
      Closes-Bug: #1285478
      4d6238ce
  35. Nov 12, 2013
    • Akihiro MOTOKI's avatar
      Import install_venv from oslo · 7a0581bb
      Akihiro MOTOKI authored
      The new version of install_venv_common evaluates requirements.txt
      and test-requirements.txt at the same time and we avoid Django 1.6
      is installed when evaluating django-nose dependencies.
      
      Change-Id: I2ab7108b3615ac6c0525089b81b80e5c0a4793fc
      Closes-Bug: #1250581
      7a0581bb
  36. Sep 09, 2013
  37. Aug 08, 2013
  38. May 29, 2013
    • Jiri Tomasek's avatar
      Renames tools/pip-requires to requirements.txt · 5b24518b
      Jiri Tomasek authored
      and tools/test-requires to test-requirements.txt
      
      These are standard files and tools in the
      general world are growing intelligence about them.
      
      Change-Id: Iac3c680dd19cabd8ea38598a6e2bb27238030a2d
      Fixes: bug #1179008
      5b24518b
  39. May 22, 2013
    • Steve Baker's avatar
      Access to heat API via python-heatclient · c949b6fb
      Steve Baker authored
      This adds python-heatclient as a dependency and a simple function
      to get a client reference.
      
      Required for blueprint: heat-ui
      
      Change-Id: I5f7d8c7c17f6e78d3f88cc39d50826416b48ad2c
      c949b6fb
    • Steve Baker's avatar
      parse_isotime filter to parse a date string. · 6b6f97f7
      Steve Baker authored
      This then allows the resulting date value to be piped
      to one of the standard django date/time format filters
      
      This is identical to oslo timeutils parse_isotime, but annotated with
      @register.filter
      
      Required for blueprint: heat-ui
      
      Change-Id: Ibecca77d50bb5c0df59e07e9572069215229f60a
      6b6f97f7
Loading