- Changed "this.fail" to "this.test.fail" in frontend regression test 4606
- Restored default timezone "Europe/Berlin"
- Added "var/log/*.log" to .gitignore
- Updated default.pp so that the user apache is part of the vagrant group
refs #4606
refs #4605
refs #4640
This commit summarizes the bugfixes made in this branch. As the frontend the fixes required a lot of stuff to be fixed afterwards and #4602 was used as a larger example regression test, this affects a few tickets:
- (Bug 4491) Frontend tests will hang randomly: CasperJS now operates on the installed version, so this shouldn't happen anymore
- (Bug 4602) Configuration Interface - Authentication: Backends moved when pushing enter: The authentication interface is reworked and does not persist a state over pages
- (Bug 4605) /tmp should not be the default log path: Now it is the application relative var/log path
- (Bug 4606) Configuration: Show message that changes were saved successfully: Implemented and tested with casperjs
- (Bug 4641) Installation/Testing fix configure/make: This has been reworked
- (Bug 4642) Allow Application placeholder in config: This was required for implementimg 4605
- (Bug 4643) Application doesn't work with older Zend Versions: A fallback __call has been implemented for this
refs #4491
refs #4602
refs #4605
refs #4606
refs #4641
refs #4642
refs #4643
the runner now supports --host, --port, --path, --user and --pass for
icingaweb access and doesn't spawn any servers by itself.
Also a login test has been added. Other tests are removed as they don't
apply anymore.
refs #4491
The PreservingIniWriter needs to be aware of the the order of the sections and
update the section declarations in the configuration file when the order has
changed. Therefore add functions to correctly reorder sections.
refs #4615
Fix coding standards in database schemes. Use DbAdapterFactory in all unit
tests instead of creating own adapters. Fix DbUserBackend and DbStore to use
FETCH_OBJ, instead of FETCH_ASSOC, to handle it consistently in the whole
application. Remove unnecessary table columns from the "account" scheme.
refs #4577
refs #4578
refs #4596
refs #4599
refs #4627
Remove old (now-unusable) module loader and components and corresponding unit
tests. Give the component loader and the component registry more meaningful names.
refs #4456
Add a component loader that finds components by searching for elements with the
"data-icinga-component" attribute and loads the corresponding JavaScript file
from the backend to render the component.
refs #4456
Change the StoreFactory configuration to reference to a resource instead of
defining the whole database. Additionally fix docstrings, fix imports and fix
function calls to comply to coding style standards.
refs #4503
Create the DbAdapterFactory to instanciate db adapters, add resources.ini to configure resources, change
the authentication Manager to fall back to backends with lower priority in case
of errors, update the current UserBackends to the changed environment. Also
adjust the documentation and existing unit tests.
resolves#4503
- Rename ConfigurationController to ConfigController
- ConfigController and PreferenceController are now subclasses of
BaseConfigController and BasePreferenceController
- Module and Application Config/Preference Tabs are detected via
the ControllerTabCollector
- Moved Controller classes to Icinga/Web/Controller (this is why
so many files are modified)
refs #4530
Implement a function to fetch comments at line end and use it to preserve
comments. Change the regular expressions used to parse lines to be more aware
of whitespaces between terms. Add automatic value and comment indentation
to produce cleaner output.
Support date, time and datetime formatting based on format strings
set either by the user or via config.ini. The view helper
FormDateTime uses the new helper already
refs #4440
refs #4424
As Widget's already denote an abstract concept, the name
'AbstractWidget' is redundant. Also this class didn't do anything except
fetching a view via a singleton (which is now injected into the render method)
and bypassing the PHP class properties by creating a 'properties' array which is
filled with magic getters and setters (which now are simply php class properties)
Further changes:
- toString is removed, as this incorporated a lot of
application logic which would cause unrecoverable
errors when throwing exceptions
- renderToHtml is now just render and the view dependency must be
passed, as a widget shouldn't be responsible for getting
view instance (this means that <?= $this->tabs ?> is now
<?= $this->tabs->render($this); ?> in the templates
- Controllers don't have $this->widget anymore as Widgets are
directly instanciated with their class, allowing better code completion
and avoiding hidden dependencies, also Widget::create is now removed
in favor of direct instanciation.
refs #4192
Add an ini writer that respects the file structure and the comments that may be
already present in the config file. Move Application/Config.php into
Config/Config.php.
refs #4352
- The CommandPipe class now delegates submission of commands to
the Transport classes (LocalPipe or SecureShell)
- Added SSH options for non-interactive mode
- Refactored tests
refs #4441
The tests now try to write to /tmp and are skipped if this folder
is not writable. Also the test has been refactored a bit (comments,
assertion messages)
regs #4461
The constructor of the class is now private, instantiation happens
with Url::fromRequest and Url::fromPath. Also updated all occurences
of Url and fixed the Qlink helper to not overwrite the baseUrl with null
values
refs #4381
Fix installation instructions for postgresql, the user table is now
'account', as user is a keyword in some rdbms, now catching exceptions
and returning auth failed while logging errors
refs #3769
Add functionality to check if a certain database type like psql or mysql is
available and skip the tests accordingly.
Add documentation for backend authentication.
refs #3769
QueryAdapter and SlidingWithBorder used the statusdat backend and
must therefore be modified.
The --strict parameter stores controller tests because of the 1s timeout
and offers now advantages for us at this time.
refs #4417
After moving StatusDat to monitoring/Backends and changing the
inheritance to Library/Icinga/Data, a few changes must be reflected in the tests:
- Move tests to monitoring module
- Change $this->backend references in StatusDat Queries to $this->ds
- Added LibraryLoader to ease requiring of libaries (to be discussed)
refs #4417
refs #4179
The history API encoded components multiple times, e.g. causing a [ to
be converted to %5B in the first link, then to %255B on the second link,
%25255B on the third, etc.
refs #4408
New namespace implementation created to load application code
like forms with this autoloader. Consumpting services can register
their own, multiple namespaces. Overlapping namespaces matched
by closest name.
refs #4407
This change leads to expected exceptions when bootstrapping the
application since the \Icinga\Application\Config class was
refactored but its usage not.
refs #4354
refs #4353
The history API encoded components multiple times, e.g. causing a [ to
be converted to %5B in the first link, then to %255B on the second link,
%25255B on the third, etc.
refs #4408
When the X-Icinga-Module-Enable header is send, the
modulemanager automatically tries to load javascript files for
that module. This is realized by adding the 'registerHeaderListener'
method to the async manager, which allows to listen to specific headers
and firing callbacks if a response with the specified header is retrieved.
Also the tests have changed a bit, requireNow should be used when using
the requiremock, so a require always loads files new.
refs #4092
refs #3753
When the X-Icinga-Module-Enable header is send, the
modulemanager automatically tries to load javascript files for
that module. This is realized by adding the 'registerHeaderListener'
method to the async manager, which allows to listen to specific headers
and firing callbacks if a response with the specified header is retrieved.
Also the tests have changed a bit, requireNow should be used when using
the requiremock, so a require always loads files new.
refs #4092
refs #3753
Added the clearstatcache call before enabling or disabling modules,
as this prevents a 'File exists' error that occurs sometimes on
symlink creation (even when the folder is empty). Also added tests
for teh moduleManager
refs #4092
- The authentication controller now uses the Authentication/Manager class,
also there were some issues in the Session creation, this has been removed
from the Bootstrap now, as the Controller must decide how to open a session
(read-only or read/write).
- The tests reflect a few chagnes, as the move from the CSRF token generation
to the Formbuilder.
- Notificaiton now doesn't use Zend Session
refs #4340
Add CasperJS Tests for History API (~80%). Also provides a few
resources like the generic.html site that can be used for more
setups
refs #4303
refs #4315
Runtest now creates a symlink to the public folder when it doesn't
exist, allowing the built-in server to access the js files
without too much hassle
refs #4303
refs #4315
Added a static folder and spawn a small HTTP server on runtests.
This is not really the best solution, as it uses pythons
simpleHTTPServer, but it works for now
refs #4315
The builder class allows to create forms and bind them to
models. The tests are currently failing because of the zend
pluginloader, this must be evaluated
refs #4302
Add CasperJS Tests for History API (~80%). Also provides a few
resources like the generic.html site that can be used for more
setups
refs #4303
refs #4315
Runtest now creates a symlink to the public folder when it doesn't
exist, allowing the built-in server to access the js files
without too much hassle
refs #4303
refs #4315
Added a static folder and spawn a small HTTP server on runtests.
This is not really the best solution, as it uses pythons
simpleHTTPServer, but it works for now
refs #4315
Behaviours are now modules and icinga.js automatically
requests module/list (which should be served by the application
and is non static) and retrieves a list of modules to request and
enable.
refs #3753
This commit adds tests for the module loader and registry of
icinga2-web. It mainly registers event handlers and calls
custom enable/disable functions
refs #3753
The getDefine method check's for existence of the 'arg' variable,
which was renamed to 'name', causing the typeof arg === "undefined"
to always return true
refs #4308
Tests can now call require('requiremock') to bootstrap an alternative
requirejs implementation and use the resulting object for defining
dependencies and mocks
refs #4308
extcmd_test contains the external-command parser from icinga-core
and allows the commandpipe tests to check if the commands would
be accepted by the core
refs #4258
The test is skipped due to the tight coupling of the Ldap Protocol
Backend to the rest of the application, this has to be addressed
as soon as the Connection is cleaned up
refs #4265
refs #4250
The function tokens in the Expression handler didn't
work after they were rewritten, as the rewrite was
missing in certain files. This is fixed now
refs #4246
As we have different executables for executing the runtests scripts,
runtests.sh is now renamed to runtests in order to stay consistent
over all testrunners
refs #4213
refs #4244
The dummy test only checks whether our build server has the correct
title when called. Also the i2w-config.js toolkit is provided
to help testing correct paths
refs #4213