There are 2 possible setups when running integration tests for
Horizon plugins.
The first setup, which we suggest to be used in gate of *-dashboard
plugins is to get horizon as a dependency of a plugin and then run
integration tests using horizon.conf config file inside plugin
repo. This way plugin augments the location of Horizon built-in Page
Objects with the location of its own Page Objects, contained within
`plugin_page_path` option and the Horizon built-in nav structure with
its own nav structure contained within `plugin_page_structure`. Then
plugin integration tests are run against core Horizon augmented with
just this particular plugin content.
The second setup may be used when we need to run integration tests for
Horizon + several plugins. In other words, content from several
plugins is merged into core Horizon content, then the combined
integration tests from core Horizon and all the involved plugins are
run against the resulting dashboards. To make this possible both
options `plugin_page_path` and `plugin_page_structure` have
MultiStrOpt type. This means that they may be defined several times
and all the specified values will be gathered in a list, which is
iterated when running integration tests. In this setup it's easier to
run the tests from Horizon repo, using horizon.conf file within it.
Keep in mind that `plugin_page_structure` needs to be a strict JSON
string, w/o trailing commas etc.
This patch as well removes leftfovers of sahara integration tests from
Horizon repo, in order for core Horizon integration tests to
pass. Sahara integration tests are moved to the CR
https://review.openstack.org/#/c/253614
Co-Authored-By: Timur Sufiev <tsufiev@mirantis.com>
Change-Id: I99718970af78feeafc25dbb3aa9639ea2cf401ad
This patch enables the PhantomJS webdriver for running
the Selenium test suite.
Use it with the --selenium-phantomjs command-line switch
when executing the selenium and integration suite.
Change-Id: I443e6f6d7d1911df500b360f7c22686b417fbeae
Blueprint: enable-phantomjs-selenium
This patch updates the file names of the coverage reports so they are
visible by default on most systems. Also updates the .gitignore, so the
new files are not pushed to the Horizon repo.
DocImpact
Closes-Bug: 1508526
Change-Id: I3c1c8f4c88819e2f49b60722ea8cc37bdc711b8c
Having screenshot of failed test might increase speed of
understanding the failure reason.
partially-implements blueprint: selenium-integration-testing
Depends-On: I0fd89ede7a3d04ce9b4bd4c8fba0789770048d40
Change-Id: Ibc4a6235423736e5938fb348bbe83211917b08d1
Establish features for running Karma tests. Separate karma configurations
are used due to current overlap of template file structure.
You can run the karma tests via:
./run_tests.sh --karma
The Karma framework allows for many features like unit test coverage and
provides a common configuration for different test runners.
Change-Id: I79680ef6369383c148da68e6677945886a48df81
Implements: blueprint karma
An .eggs/ directory was being created when running
tox -r -e jshint, we should be ignoring egg artifacts
so be more aggressive in what's ignored for eggs.
The old horizon.egg-info entry is covered by the new
ignore entry.
Change-Id: I54de1f603c1c9867fd3ca3e676b5a3fe36d2ab3e
This command allows to easily save a diff between local_settings.py and
local_settings.py.example to reapply the change when local_settings.py.example
changes (per branch switch or updates).
implements bp settings-migration-script
Change-Id: I2668bbf248434a5d437a5fc46ad07c1a1f29b793
Lock files being left behind by oslo_concurrency were not gitignored so
it was likely they would end up in commits by accident, this patch adds
*.lock to the .gitignore to prevent this.
Change-Id: I06d5eda51e84af0e7afa64315b47a6a651ef41ec
Closes-Bug: 1415576
A kind of binary files are useless to be maintained in git repo.
I18N team and package distributors have agreed to remove compiled
message catalogs from Horizon git repository.
The instruction on how to compile message catalogs will be
covered by https://review.openstack.org/#/c/126169/
or the installation guide.
DocImpact
Change-Id: I81b05cf79c21d85bed8a6da6df659955e7ac58c5
Closes-Bug: #1196982
The current wsgi does not support virtualenvs (in some distributions, the
dependencies may conflict with the distribution's python packages/dependencies
and would require a virtualenv even in production).
Also, making an apache web configuration is not always trivial especialy
with ssl.
This "make_web_conf" command creates a wsgi with automatic virtualenvironment
detection (if there is a virtualenvironment), and creates an apache
(normal or ssl) configuration
TODO(ygbo)::
- add nginx support to generate nginx configuration files.
- add gunicorn support.
- add uwsgi support.
implements bp web-conf-generation-script
Change-Id: I6397ba01df88b540bbdca4bf21ba90be6843022a
To ignore swap files from getting into repository
currently the implemented ignore is *.swp
however vim adds more swap files if these files exists,
so improving this with *.sw?
Change-Id: I91c799acfe186791061cd91414f606fd7cf08fb7
Closes-Bug: #1255876
Implements blueprint automatic-secure-key-generation
Reduce the likeliness that the (commented-out) default key is abused
and document possible options instead.
Also use a non-empty SECRET_KEY for development / testing environments.
A later patch would make it a hard error if no SECRET_KEY is defined
(i.e. Django defaults to an empty string which is anything but secure).
Unfortunately, I can't do it now as the devstack integration test would
fail (they don't set a SECRET_KEY either) currently. So, when this
blueprint is accepted, I would submit a fix to devstack and afterwards
add the error message to warn the user about insecure defaults.
Addressed PEP-8 issues
Change-Id: Ifdab8e6b6fb3025fde7a2b92beb046ec9c5cba7f
To better facilitate the building and publishing of sphinx
documentation by Jenkins we are moving all openstack projects with
sphinx documentation to a common doc tree structure. Documentation
goes in project/doc and build results go in project/doc/build.
Change-Id: Ic523a716e4113198b777d6dc3db8bb8a729e7696
This changes all of the Bootstrap CSS and Horizon
CSS to use LESS. Horizon's specific CSS will be
organized into separate files in another commit,
as it is outside the scope of this BP.
We are also now packing LESS 1.3.0 directly within
Horizon.
Implementation of Blueprint transition-to-lesscss
Change-Id: Ie4be8b28ab3ce04ea21d7d5cd49c2ccb66bd8ade
Horizon is the last project that doesn't have support for the common
Project Testing Interface. This gets horizon up to speed with the
other bits, but shouldn't break any of the existing interfaces.
Change-Id: I464c3b10d9708a0b7b5ffd42c88cd3cf515ef6a7
There are no longer two separate projects living inside the horizon
repository. There is a single project now with a single setup.py,
single README, etc.
The openstack-dashboard/dashboard django project is now named
"openstack_dashboard" and lives as an example project in the
topmost horizon directory.
The "horizon/horizon" directory has been bumped up a level and now
is directly on the path when the root horizon directory is on
your python path.
Javascript media which the horizon module directly relies upon
now ships in the horizon/static dir rather than
openstack-dashboard/dashboard/static.
All the corresponding setup, installation, build, and env scripts
have been updated accordingly.
Implements blueprint unified-packaging.
Change-Id: Ieed8e3c777432cd046c3e0298869a9428756ab62
Adds a base Usage data object, datatables, class-based views,
and more consistent templating for all cases.
Bumps environment version to ensure latest novaclient.
Fixes bug 922353.
Change-Id: Ib2042e9393c8deb0e3ec23403da55a6fb8dd39fb
Buildout has been removed entirely, all dev installation is now
done via the single tools/install_venv.py script.
Django's manage.py script has also been updated to a newer
version/convention; this allows for less python path mangling
and makes things cleaner and more explicit. Note that, as such,
it has been moved up a directory level.
Change-Id: I62f9f06ee00568fc91e5ba7e1fd15d22ea849d1f
Removes the fake_render_to_response function that was preventing
templates from being rendered. This required a number of adjustments
to the mocked obejcts in the view tests (which didn't need to be
mocked to begin with). A couple of legitimate problems were
exposed upon rendering the templates which are also now fixed.
Change-Id: I1647dcec01084318be1bb8f6d6ac1f4308992afa
Implements blueprint environment-versioning.
Fixed bug 887885. The script will bail if the seleniumrc or test scripts are missing, preventing the hang, or the possibility of bad environments.
Change-Id: I3cdeb71660c897e8b2adbf81d3794333d1847204
Implements blueprint frontend-testing.
Implements blueprint javascript-unit-tests.
Adds selenium to buildout script and uses django-nose-selenium to integrate with Django's unit test machinery. Includes proof-of-implementation tests with both selenium and qunit.
Change-Id: Ic7db4994be398c633a78dca7369359602c7d8f57
Implements blueprint extensible-architecture.
Implements blueprint improve-dev-documentation.
Implements blueprint gettext-everywhere.
Implements blueprint sphinx-docs.
Complete re-architecture of the dashboard to transform it from a standalone django-openstack app to a Horizon framework for building dashboards. See the docs for more information.
Incidentally fixes the following bugs:
Fixes bug 845868 -- no PEP8 violations.
Fixes bug 766096 -- the dashboard can now be installed at any arbitrary URL.
Fixes bug 879111 -- tenant id is now controlled solely by the tenant switcher, not the url (which was disregarded anyway)
Fixes bug 794754 -- output of venv installation is considerably reduced.
Due to the scale and scope of this patch I recommend reviewing it on github: https://github.com/gabrielhurley/horizon/tree/extensible_architecture
Change-Id: I8e63f7ea235f904247df40c33cb66338d973df9e