Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests/lib
AgeCommit message (Collapse)Author
2022-02-27[Vue] wait for vue to flush queue in waitForNetworkIdle() to reduce UI test ↵dizzy
random failures (#18853) * wait for queued vue logic if any in waitForNetworkIdle to reduce rate of random failures * only do if vue is available
2021-12-10[Vue] migrate widget-loader directive (#18428)dizzy
* do not decode model value of site name in site selector, so it is always the same as what is in the DB * 4.6.0-rc2 * more ng-model fixes * rebuild * html tweaks * add timeout to test * rebuild * fix another UI test * rebuild vue files * update some expected screenshots * fix more issues * Revert "[Vue] do not decode model value of site name in site selector, so it is always matches the DB value (#18356)" This reverts commit 8c7539f073e7a49311cbe6dc2474eb1bbfb8718d. * update screenshots * more fixes * another fix + screenshot update * more screenshot updates * more fixes * even more fixes * another ui test fix * more type fixes * rebuilt vue JS * couple more fixes * undo debugging * do not convert undefined to bool * update screenshot * another bool checking fix * rebuild vue files * more fixes * initial site value in field is assumed to be encoded * file headers and custom field component support * get custom component field code to work * rebuild vue * allow using angularjs templateFile for custom field (for BC) * get angularjs template embedding to work for rollupreporting at least * deal with some in source TODO items * fix a couple more issues * Use separate div in modals to display notifications otherwise Vue will erase modal content when initializing NotificationGroup component. * build again * refactor some code and fix an issue with checkbox array field handling in angularjs * more fixes * another fix * even more fixes * remove more todo * hopefully the last changes * update vue files * update submodule * revert debugging change + fix issue * built vue files * fix another select issue * rebuild vue files * fix broken refactor * update two screenshots * add some more timeouts and update screenshots * initial conversion, loading w/o error * tweaks * get period selector work in UI * fix site selector model binding * rebuild vue * fix viewDate not being kept in sync * rebuild CoreHome * [Vue] fix modal notification placement (#18377) * Use separate div in modals to display notifications otherwise Vue will erase modal content when initializing NotificationGroup component. * built vue files * two fixes * couple UI test fixes * rebuild vue * update files * sidenav start * make getRef a utility method * tweak * add return type * finish converting side-nav directive * starting on reporting menu conversion * remove unused properties * convert reporting pages service * migrate report metadata store * remove angularjs files * migrating reporting pages store * make store adapters more immutable * get service adapters to work * fix a UI test * another html fix * migrate most of reporting menu directive and model * Use themed font family for input forms to override materialize.css styling * rebuild vue * add a missing div * ui test fixes * update styling * get to build * get to load in the UI w/o error * clone result of functions * fix compile issue * migrate widget loader and get to load in UI * rebuild vue * Updating version to 4.6.0 * update expected screenshot * add wait just in case travis is slow * fix ordering bug * add another wait * rebuild vue * css tweak * fix some bugs and tests * undo screenshot changes * Menus test passing locally * [Vue] date picker viewDate property is not kept up to date (#18385) * viewDate ref is not kept up to date * rebuild corehome * reporting menu subcategory items are meant to be normal links * update some screenshots * use innerText instead of text() since angularjs maintains newlines in HTML that vue does not add * trigger angularjs digest after ajaxhelper request * rebuild vue * update screenshots, fix bug in link generation in reporting menu and allow syncing multiple screenshot regexes at a time * undo box-shadow change for UI tests * fix more issues & update more tests * update some screenshots * fix some tests * rebuild CoreHome * quick fix * built vue files * fix angularjs issue * add comment * update umd files * 4.6.1-rc1 * 4.6.1 * fix field array title * apply some pr feedback * apply more pr feedback * another fix * tweak * fix ng-change not executed before ng-model * fix another set of issues * fix another issue * rebuild vue * better ng-change/ng-model fix * update some screenshots * rebuild vue * remove some TODOs * initiate initial ng-change ONLY for site selectors where this behavior applies * emit/broadcast on correct scope in wrapper * rebuild vue * fix some issues * fix another title issue * built vue files * fix function signature * fix vue warning * fix ajax request race condition * rebuild vue * add new notification type "help" so the help notification is not cleared when clearing transient notifications * fix some bugs and tests * update screenshot * update screenshot & fix a test * allow using unminified jquery ui + fix bug in last fix * fix error when enrichedheadline is used in modal * add polyfill min.js * remove two todos * fix widget url logic * update some screenshots and fix sanitization/escape issue * update screenshots * rebuild vue * fix url location updating regression in MatomoUrl.updateLocation use * submodule * update screenshots and fix possible error in json parse * built vue files * Merge branch 'vue-period-selector-regression' into vue-reporting-menu * rebuild vue * use correct variable * rebuild vue * fix widget url logic * segment parameter can be undefined now for some reason * fix ngmodel binding in siteselector adapter (for last time hopefully) * the original site selector only set the first site to the first site in the initial sites query if there was only one site in the entire matomo instance * fix sitesmanager ui test failure * fix usersettings test failure * rebuild vue * more siteselector tweaks. * build CoreHome * more siteselector tweaks. * another siteselector issue * update screenshots * update screenshot and try to fix random failure * fix couple tests * apply review feedback * fix ngmodel render issue w/ extra nextTick() * Update plugins/CoreHome/stylesheets/layout.less Co-authored-by: Stefan Giehl <stefan@matomo.org> * fix js test error * updates expected UI files Co-authored-by: Matthieu Aubry <mattab@users.noreply.github.com> Co-authored-by: Justin Velluppillai <justin@innocraft.com> Co-authored-by: justinvelluppillai <justinvelluppillai@users.noreply.github.com> Co-authored-by: sgiehl <stefan@matomo.org>
2021-12-01[Vue] migrate piwik-field and related directives (#18352)dizzy
* forgot to remove old files * built vue files * first pass at migrating notification directive, notification service and parts of UI.Notification to Vue * rewrite URL handling to use computed properties in a URL store + do the same for other dependent data in the comparison store to allow vues to subscribe to the properties for changes to global state * fix some tests * some more fixes * more fixes + disallow modifications to MatomoUrl state * get angularjs unit tests to pass + fix a couple more issues * another fix * fix bad merge * self review + fixes * remove old fix as it may not be needed anymore * empty string is not a valid date + do not report invalid date exception just rethrow * update screenshots and try to fix random failure * use jquery $destroy event instead of scope one since the scope one is broadcasted * rangeChange event must be triggered once on mount * initialize startDateText/endDateText correctly * use jquery $destroy event instead of angularjs one * built vue files * fix menudropdown.directive.js reference * load vue in installation/updater & correctly make focusanywherebuthere stateful * correctly implement stateful directives for ExpandOnClick/ExpandOnHover * less tweak (angularjs comment removal) * fix submenu check * quick type fix * load vue in installation workflow * add broadcast.js to Installation workflow + do not fail in pk_translate if no translations are loaded * update expected screenshots (spacing of arrow changed because of angularjs comment no longer being there) * start moving Notification class code to notifications store * fix prop type * fix html escaping * built vue files * get toast and other transitions to work + fix broken toast * move all of notification.js to NotificationStore * wait for angular to be initialized to post events to avoid loading race condition * get scroll to notification to work + get initialization of notification groups to work * correct unmount + remove notifications service file * fix some test failures * re add accidentally removed (?) file * remove no longer needed file * Add CoreHome UMD in CoreUpdater/Installation. * self review * fix type + add default value * remove file from JS list * fix test * fix UI tests * set correct type in users manager notification and allow scope values to be transformed in createAngularAdapter * start converting form field directives * start migrating siteselector * small addition * migrate rest of site selector code + make some breaking changes to function signatures in createAngularJsAdapter * disable webpack asset size hints/warnings + get siteselector code to build * fixing some bugs * fix some more issues (allow specifing require in createAngularJsAdapter and make AjaxHelper promises abortable) * get npm test to pass * a couple more fixes * remove existing files * convert quick-access directive and use shared code/state with site selector * remove site selector model * fix more issues and get UI tests to pass for quickaccess * remove debugging code / todo * fix initial value * add back a $timeout() * fixing tests, the post blur scope.$apply()s are apparently required for angularjs to function properly * migrate field-array * fixing more UI test failures * rebuild * start converting multipairfield * fix vue build * why were these deleted? * remove debug code * first pass migrate multipairfield.vue * move form-field code relevant to selects to FieldSelect.vue * fix css class issue + update expected screenshots * rebuild CoreHome * move more of form-field.directive.js to new vue classes * revert styling change * finish converting last of form-field.directive.js code (completely untested) * built vue files * get focus-if to work and remove debugging return; * rebuilt vue * should not need to specify type there * built CoreHome * built vue files * Fix for misaligned evolution trend icons (#18323) * Aligned evolution trend icons, text tweak * Update plugins/MultiSites/angularjs/dashboard/dashboard.directive.less Co-authored-by: Stefan Giehl <stefan@matomo.org> * apply review feedback * Hide feedback banner in zen mode (#18329) * [Vue] 4.6.0 fixes (#18334) * feedback plugin may not be loaded * fix copy paste * async/await not supported * built UMDs * get local files to build * built files * get auto clearing behavior to work in site selector * fix a couple more bugs * use jQuery click for expand on click * undo submodule change * rebuild vue * get vue files to run * missing element * more fixes * get more fields working properly * rebuild * fix even more issues * [Vue] use jQuery click for expand on click (#18341) * use jQuery click for expand on click * undo submodule change * migrate piwik-field directive and fix some issues * forgot to add migrated directive files and get demo.twig to work * use event target * make sure angularjs and vue do not share data * fix ng model mapping * fix a couple more issues * fix a couple more bugs * more fixes * mimic existing behavior where an empty value will result in an extra field appearing in a select option list, but only at first * another fix * built vue files * more fixes * do not use UMD if vue/src is not present * use non-minified angularjs if in development mode * deprecate custom template file property * remove angularjs properties in scope properties (ie, $$hashKey) otherwise vue will fail when it tries to process them * fixing some more issues from ui tests * more fixes * fix form field issue + patch jquery so .trigger() will also trigger events added via addEventHandler() * true bc fix * get the jquery patch to work * ignore polyfill map * fix ng-model issue in report limit in report export directive * full width property was not handled properly before in angularjs * do not try and parseInt null values * fix several more issues for tests * fix some tests * fix data binding * fix css class * fixing more ui test issues * do not decode model value of site name in site selector, so it is always the same as what is in the DB * 4.6.0-rc2 * more ng-model fixes * rebuild * html tweaks * add timeout to test * rebuild * fix another UI test * rebuild vue files * update some expected screenshots * fix more issues * Revert "[Vue] do not decode model value of site name in site selector, so it is always matches the DB value (#18356)" This reverts commit 8c7539f073e7a49311cbe6dc2474eb1bbfb8718d. * update screenshots * more fixes * another fix + screenshot update * more screenshot updates * more fixes * even more fixes * another ui test fix * more type fixes * rebuilt vue JS * couple more fixes * undo debugging * do not convert undefined to bool * update screenshot * another bool checking fix * rebuild vue files * more fixes * initial site value in field is assumed to be encoded * file headers and custom field component support * get custom component field code to work * rebuild vue * allow using angularjs templateFile for custom field (for BC) * get angularjs template embedding to work for rollupreporting at least * deal with some in source TODO items * fix a couple more issues * Use separate div in modals to display notifications otherwise Vue will erase modal content when initializing NotificationGroup component. * build again * refactor some code and fix an issue with checkbox array field handling in angularjs * more fixes * another fix * even more fixes * remove more todo * hopefully the last changes * update vue files * update submodule * revert debugging change + fix issue * built vue files * fix another select issue * rebuild vue files * fix broken refactor * update two screenshots * add some more timeouts and update screenshots * fix site selector model binding * rebuild vue * fix field array title * apply some pr feedback * apply more pr feedback * another fix * tweak * fix ng-change not executed before ng-model * fix another set of issues * fix another issue * rebuild vue * better ng-change/ng-model fix * initiate initial ng-change ONLY for site selectors where this behavior applies * update screenshots and try to fix random failure * undo submodule change * fix test Co-authored-by: sgiehl <stefan@matomo.org> Co-authored-by: Ben Burgess <88810029+bx80@users.noreply.github.com> Co-authored-by: Matthieu Aubry <mattab@users.noreply.github.com>
2021-11-28Include another local file if present in UI tests to allow extending the ↵dizzy
framework. (#18392)
2021-11-13add feedback question, remove other related. (#18262)Peter Zhang
* remove feedback links remove feedback links * update screen shot update screen shot * add feedback question add feedback question * update close to icon update close to icon * built vue files * remove in line css remove in line css, change to less file * move translation key to plugin move translation key to plugin * remove feedback popup remove feedback popup * update remove some test and feedback related update remove some test and feedback related * add draft tests add draft tests * update feedback add php and UI tests update feedback add php and UI tests * update test screen shots update test screen shots * Update demo.twig add heart to demo page * add feedback back in extend the modal add feedback back in extend the modal * update coreHome update coreHome * update screen shots update screen shots * Update FeedbackQuestion_spec.js update js tests * update test update test * built vue files * update screenshot and js tests update screenshot and js tests * Update FeedbackQuestion_spec.js test success * update screenshot update screenshot * update tests update tests * fix test error fix test error * Removing the refer us popup * Readding accidentally removed language files * update test * update test * remove refer us * update feedback umd js update feedback umd js * merge Andy branch merge Andy branch and update screen shots * revert language changes revert language changes * revert language changes revert language changes * revert language file revert language file * revert unrelated lang change revert unrelated lang change * revert lang change revert lang change * revert lang change revert lang change * Delete ControllerTest.php remove controller test not in used * Update core/Piwik.php Co-authored-by: Ben Burgess <88810029+bx80@users.noreply.github.com> * Update plugins/Morpheus/javascripts/piwikHelper.js Co-authored-by: Ben Burgess <88810029+bx80@users.noreply.github.com> * update a big that cancel and reopen it again update a bug that cancel and reopen it again * update compare error update compare error * Update plugins/Feedback/FeedbackReminder.php Co-authored-by: Stefan Giehl <stefan@matomo.org> * update feedback show logic update feedback show logic * Update FeedbackQuestion_spec.js update tests * Update Feedback.php remove comments * Update .gitignore * update vue build file update vue build file * built vue files * update vue build file update vue build file * add close button add close button * add close button add close button * update screenshot update screenshot * remove umd remove umd * git add corehome git add corehome * revert all the umd file revert all the umd file * built vue files * built vue files * Update plugins/Feedback/lang/en.json Co-authored-by: Stefan Giehl <stefan@matomo.org> * update per review update per review * built vue files * set auto focus on modal open set auto focus on modal open * built vue files * Update FeedbackQuestion.vue add please write in english * built vue files * remove please write in English remove please write in English * built vue files * update tests and question tests update tests and question tests * set cookie in the test set cookie in the test * Update page-renderer.js add setCookie to tests * update test only load 1 update test only load 1 * built vue files * Update FeedbackQuestion_feedback_popup.png update screen shot * Update piwikHelper.js update button css * update screen shot update screen shot * Update plugins/Feedback/Feedback.php Co-authored-by: Stefan Giehl <stefan@matomo.org> * Update plugins/Feedback/vue/src/FeedbackQuestion/FeedbackQuestion.vue Co-authored-by: Stefan Giehl <stefan@matomo.org> * Update plugins/Feedback/API.php Co-authored-by: Stefan Giehl <stefan@matomo.org> * Update plugins/Feedback/API.php Co-authored-by: Stefan Giehl <stefan@matomo.org> * Update core/Plugin/API.php Co-authored-by: Stefan Giehl <stefan@matomo.org> * update cookie and tests update cookie and tests * built vue files * test setcookie in tests test setcookie in tests * update tests update tests * update tests update tests * Update FeedbackQuestion_spec.js update cookie test * extend setCookie in test extend setCookie in test * update elints format update elints format * built vue files * test set cookie test set cookie * built vue files * Update FeedbackQuestion_spec.js set cookie after goto URL * Update FeedbackQuestion_spec.js int to string * update set cookie update set cookie * update test URL update test URL Co-authored-by: peterhashair <peterhashair@users.noreply.github.com> Co-authored-by: Andrew Davis <andrew.affinity@gmail.com> Co-authored-by: Ben Burgess <88810029+bx80@users.noreply.github.com> Co-authored-by: Stefan Giehl <stefan@matomo.org>
2021-11-09Mark IE11 as no longer supported browsers (#18199)Thomas Steur
* Revert "add warning about dropping support for users using IE (#18037)" This reverts commit 962bd82b8069af16bb5fcfcc7d2ef75731a5bf2e. * Mark IE11 as unsupported browser * update browserslist dependencies to > 0.05% usage * update other browser versions * debug browser not supported ui test failure * reset user agent in optoutform UI test * reset user agent after optoutform test * another user agent in tests tweak * remove supported browser debugging output Co-authored-by: diosmosis <diosmosis@users.noreply.github.com>
2021-10-06[Vue] migrate periods service to typescript & introduce frontend unit ↵dizzy
testing for vue & migrate periods.spec.js (#18092) * initial periods service conversion * get period service migration to compile * getLastNRange was public static * fix an issue, switch angularjs tests to use chrome headless and hope it works * remove phantomjs requirement * get vue unit testing to work w/ jest (only option right now, the mocha plugin is not compatible w/ vue 3 and no one is working on making it compatible) * more test code * progress * more progress * more progress, single passing test * finish converting periods.spec.js and get test to pass * remove use of any in periods service and rebuilt corehome * add missing file headers * fix run-once.sh * debug travis build * remove debugging code & update submodule * update submodule * more travis debugging * install npm dependencies in "install-ubuntu.sh" * use latest node * try this again * typos * more debugging * more debugging * testing something * testing something else * testing something else * testing something else * testing something else * testing something else * testing something else * testing something else * testing something else * testing something else * testing something else * revert travis.yml changes * update some expected screenshots * releasechecklisttest fix
2021-09-21Improves Overlay UI tests (#17920)Stefan Giehl
2021-09-09automatically wait for lazy images in UI tests (#17981)Stefan Giehl
2021-09-08Fix failing UI tests (#17970)Stefan Giehl
2021-09-01Use newer version of Puppeteer for UI tests (#17880)Stefan Giehl
* Use latest version of Puppeteer for UI tests * use newer node on travis * test * use waitForTimeout / waitForSelector instead of waitFor * Handle BC for removed waitFor method * Updates expected UI test files * update submodules * improve/fix some UI tests * Updates expected UI test files * improve/fix some UI tests * update url-parse dependency * simplify some UI tests * update screenshot * avoid using merged assets that are broken * fix expected compare exit code * don't use merged assets for TwoFactorAuth UI tests it seems due to too many requests to login, logout and other pages merging the CoreJS assets somehow fails, and results in returning an empty file. Even the reload fails to serve the correct content, so maybe the file, the content should be written to, is somehow locked. Disabling the merged assets seems to fix this issue for this tests. Locally the tests are also running correctly with merged assets. * improve handling of automatic css / js reloading in UI tests * increase timeouts of TwoFactorAuth UI tests * fix 2fa ui test * revert change * update new screenshot * updates UI screenshots * submodule updates
2021-08-10Fixing some test failures (#17852)dizzy
* fix controller test * debug travis failure * debug some more * more debugging * more debugging * another debug * another debug * more debug + fix test? * remove debug changes * remove forced failure * ui test change, check status in assert for more information in test output * check image magick status AFTER comparison threshold check * try to debug test performance on travis * try to speed up some tests * fix test change * fix test * update two screenshots * update UI test again and fix random failure hopefully * try to get rid of some more random failures * some more debugging * try fixing some more random failures * stop using screenshotSelector in some tests since it (inexplicably) cant find jquery on the test page + mysqli test * another ui test tweak * trigger new build * try fixing more random failures * updates expected test file Co-authored-by: sgiehl <stefan@matomo.org>
2021-06-11Updates some npm dependencies for screenshot tests (#17663)Stefan Giehl
2021-03-15also try reloading core js if request failssgiehl
2020-08-12also create a node_module symlinks for tests directly using files from theresgiehl
2020-06-29Try to avoid ui test failures due to CSS loading failures (#16122)Stefan Giehl
* Try to dynamically reload CSS file if it fails loading during a UI test * updates some expected screenshots * always display css reload info * also reload on failure * wait for loading styles * updates expected screenshot * wait a bit for loading css * improve reload mechanism * print css response * print headers * avoid saving empty compressed files
2020-06-14do not prefix url if it is about:blank in ui tests (#16064)diosmosis
2020-06-08Switch from bower to npm and update JS libraries (#14082)diosmosis
* Starting to replace bower with npm: use updated jquery-ui from npm. * Use jquery from npm./ * Use angular from npm. * Add more angular libraries. * Use chroma-js from npm. * Remove html5shiv, does not appear to be used. * Use iframe resizer library from npm. * Add jquery-mousewheel * Add jquery.dotdotdot from npm. * Get jquery.scrollto from npm. * Get jscrollpane from npm. * Get materialize-css from npm. * Get mousetrap from npm. * Remove ngDialog, as it is no longer used. * Install qrcode.js from npm. * Get sprintf-js from npm. * Get visibillityjs from npm. * Remove bower.json. * Getting parts of matomo to work w/ new versions of libraries installed by npm. * Ignore node_modules subfolders in node_modules since we only use npm for frontend dependencies + fix a test. * Fix button padding. * Fix series picker checkboxes. * Fix karma conf. * Fix CSS in right place. * Fixing more css/less issues. * More test fixes. * Limit selection style fix. * Fix more tests + materializecss issues. * Fix a couple more tests. * Fix annotation styling. * remove error * add ng-dialog files * try to fix some tests * Fix several UI tests. * fixing more build issues * Fix several more tests and issues. * fixing more tests * split ui tests into 3 groups * fix several more issues and tests * Fix some console warnings on chrome. * Updating more test files. * fix some tests * yet more fixes * couple more fixes * another form fix * Fix some tests. * update screenshot * update more expected files * Fix two more form issues. * test commit (travis is not fetching submodules for some reason...) * remove scripts removed in merge * three travis builds * split UIIntegrationTest into multiple suites * lets try this again * updae several expected screenshots * fix some more tests * fix plugin details material select and tabs initiaialization * update screenshots + css fix * re-initialize materialize tabs since we load jquery-ui afterwards for datepicker which unsets materialize tabs * update more screenshots and fix couple more issues * update more screenshots + tweak to test * more fixes and screenshot updates * fix some issues and update more screenshots * update submodules * more fixes + more updated screenshots * more css fixes and test fixes * couple fixes & updated screenshots * update screenshots * fix random failure * Map old bower_component files to new ones in AssetManager. * Remove node_modules from PR and ignore node_modules in .gitignore and remove libs/jquery (adding new required libs). * Update .travis.yml. * update screenshots * fixing some more issues * fix copy pasta * update screenshots * fix more modal issues * Update css & screenshots. * correct close modal calls * fixing more issues * data-target instead of data-activates * fix more tests * trigger build that works? * fix more tests * update submodule * debugging travis * more debugging * try to fix test * fix modal no button click in test * update more screenshots * couple more test fixes * some more fixes and updated screenshots * update screenshots * apply some review feedback * Fix modal centering and initial top position. * apply some more pr feedback * another pr fix * update submodule * remove style * fix color of checkbox mark * Fix centering the popover Note: centering the popover relative to body doesn't work poperly anymore, maybe because of the fixed position of the widget overlay. Using the ui-widget-overlay to position the dialog centered seems to work * ignore line endings check for node modules * updates expected UI files * submodule updates * use minified file of jquery.browser.js * updates expected test files * ensure to hide parent tooltips when row action tooltips are shown * tweak less for datatable navigation * style is only useful for dashboard * update some screenshots * update submodules Co-authored-by: sgiehl <stefan@matomo.org>
2020-04-27Run UI tests of submodules with core build if possible (#15844)Stefan Giehl
* skip only ui tests with special needs in core build * apply review feedback
2020-04-24Update doc blocks with new name (#15857)Stefan Giehl
* update doc blocks with new name * submodule updates * updates expected UI files
2020-04-02use latest puppeteer for screenshot testing (#15767)Stefan Giehl
* use latest puppeteer for screenshot testing * updates expected UI screenshots
2020-03-01place failure screenshots in plugin directory if plugin option is given (#15643)Stefan Giehl
2020-02-24Merge branch '3.x-dev' into 4.x-devsgiehl
2020-02-22Try to determine the region iso code based on it's name if not available ↵Stefan Giehl
(#15592) * Try to determine the region iso code based on it's name if not available * Adds test for region without code
2020-02-20Fix couple issues w/ samesite handling in session, make sure session … ↵diosmosis
(#15561)
2020-02-03Removes deprecated console param --piwik-domain (#15503)Stefan Giehl
2019-11-12Ignore SSL errors in UI tests (#15148)Thomas Steur
Most of our UI tests are running on http but sometimes some actions may require HTTPS and redirect to HTTPS automatically. I had this issue locally and got ` Error: net::ERR_CERT_AUTHORITY_INVALID at http://example.com/tests/PHPUnit/proxy/?idSite=1&period=day&date=2010-01-03&module=MobileMessaging&action=inde` I reckon there shouldn't be a down side to ignoring SSL errors in our tests?
2019-09-30Compare segments and periods (in API and UI) (#14365)diosmosis
* Allow row metadata to be datatables in API output. * Fill out initial DataComparisonFilter. * fixing some issues * couple more fixes * couple more fixes + initial system test * more fixes * Finish up segment comparison system test and get to pass. * Soft limit for number of segments/periods. * Add supportsComparison method. * Add UX code for adding/removing/seeing data comparisons + code to forward query parameters in AJAX requests + allow broadcast to handle multi-value query param values. * Start showing comparison tables in html tables. * Adding all comparison rows to html table visualization and adding "all visits" segment translation and add currently selected segment to comparisons table. * Show totals ratio for comparison rows. * finished poc html table visualization support for comparison * start working on comparisons support in graph visualizations * Some UX tweaks to htmltable and add comparisons to bar/pie graphs. * Getting comparisons to work in evolution graphs. * Get row evolution to work properly in comparison table. * Get segmented visitor log to work in comparison tables. * Fix regression in comparisons in evolution graph. * Get comparisons to work in actions datatable, fix twig issue that results in 100% cpu usage (when reading dataTable param w/ many rows & comparison tables), get overlay/transitions icons to appear, overlay should work properly. * Get transitions and overlay to work in comparison rows. * Fixing some datatable API output issues, fixing tests, support comparisons in subtables by forcing idSubtables of comparisons to be sent in request (makes UI work, but not pracitcal for API). * Remove typo. * apply original change * Allow All Visits default segment to be compared. * working on disabling currently compared segments. * Get currently compared segments code to work. * starting on refactoring datacomparisonfilter * Most of refactor done. * Get tests to pass and fix a bunch of datatable metadata consistency issues. * Modify evolution graph to modify compare parameters and show some sort of accurate comparison line graphs. * Set xaxis labels correctly in tooltips and make sure series data for comparisons is set correctly. * more fixes to displaying evolution comparisons where compared date ranges vary in length + make sure normal reports w/ no data display the no data message even when comparing * Show period type in comparison card. * Unsanitize compare segments. * Get correct period count. * Couple more fixes to evolution graph series labels, but still wonky. * Include comparison series label in comparison output so evolution graph has an easier time of building series data. * For multi period vs multi period show correct compareDate/comparePeriod for child tables. * Redesign period selector comparison section and get to work. * Allow plugins to disable comparisons for specific pages. * Start supporting comparison in sparkline visualization. * Get sparkline points & lengths to work correctly when comparing. * Fix comparison enabling check. * Pick series and shade colors. * Rewriting comparison card to show individual serieses. * Rewrite comparisons cards to only show segments as cards and individual serieses inside the cards. * Use comparison colors and shades in evolution graph + fix a couple bugs. * Tweak series colors and fix a couple regressions to comparison totals calculation. * Add ratio tooltip suffix explaining comparison percent. * fix typo * Forward comparison params in report export. * tweak series colors again + add tooltip with visitssummary metrics to comparison rows + fix a bug in using array query params in piwik-api + fix bug in formatting of comparison table metrics * Tooltip fixes, start on sparklines supporting comparison, modify comparison filter to only calculate change metrics against periods since they are time related. * Sparkline comparison support. * Tweak line thickness and set metric index properly in jqplot data generator. * In sparklines comparison, show evolution for compared period, rewrite top tooltip to be better, fix tooltip issues when multiple metrics used in evolution graph, and get comparison to previous period to work. * Update submodule * Make things look ok w/ a very long segment name, add numbers to compared datatable row labels, fix pie chart colors + a couple other regressions. * more bug fixes * Fix query param retrieval issue. * Do not throw if no comparison params specified, just do nothing. * try to fix a couple warnings * Another query param get fix. * Do not save comparison parameters. * pass by reference * fix JS error * DO not set compare params if not set in URL for dashboard widgets. * Fix comparison table styling in dashboard. * Expand bar graph if there are too many bars when comparing. * tweak comparison bar graph sizing * make sure flatten works w/ comparison * Apply compute processed metrics to comparison tables. * Hack to get Goals.get to be formatted during comparison. * Fix ordering of yunits in evolution graph. * If rows are selected, incorporate into comparison series names. * Format revenue properly in goals comparison sparklines. * First working attempt at adding Referrers.get method for use w/ Sparklines visualization. * get referrers sparklines to work w/ comparison * Finish using new referrers API method and get referrers sparklines/evolution graph to play well w/ each other in comparison mode. * Simplify table comparison view if only comparing periods, no segments. * Take into account visible rows when calculating series metric index. * Get comparison to work when totals rows are added to tables. * Show series color in evolution graph tooltip. * Fix error when loading row evolution/segmented visitor log for compared ranges. * fix regression in normal subtable loading * Fix row style * Forward comparisonIdSubtables parameter if present so it is used when changing limit/offset * Initialize the row index prefix to the filter offset. * Do not show period header if only segments compared in table. * Add UI tests and fix issues so they pass locally. * quick tweak * Fix PHP error * Updating screenshots * Fixing several bugs and updating expected screenshots. * Fix comparison tests and clear some TODO. * Prefix referrers metrics. * Revert "apply original change" This reverts commit 8f6ceb0430e5c7306a777498199ad7db21fd7175. * Show period label if comparing two periods of same type. * segment sanitization fixes * More segment fixes. * Another fix to the tooltip. * Fix related reports when comparing + make totals tooltip clearer + store segment + pretty title in datatable metadata so it does not have to be looked up every time. * Allow disabling comparisons for individual uses of visualizations. * Remove limit on hover for actions tables + fix subtable expansion for normal actions tables. * Make sure parameters are arrays. * Stricter check for empty parameters. * Allow first compared segment to be "removed". * several more fixes * Fixing table cell alignment and width and everything else that broke while making changes (hopefully). * Several fixes, including xss fixes and test fixes and bug fixes for comparisons. * more table css tweaks * Correct workings of previous period/year comparison + always convert periods to ranges when comparing in evolution graph. * Correct workings of previous period/year comparison + always convert periods to ranges when comparing in evolution graph + more css tweaks. * fix more test regressions * Forgot to add file * fix several TODO as well ass get comparison sparklines to have right colors in widgets. * Use DataTable metadata instead of getting available segments. * When comparing periods that do not uniformly support unique visitors, do not display unique visitors metric. * Small refactor and make sure sparklines shows over period w/o using lastN. * more refactoring and fixes * some more refactoring * Move comparison index math to helper methods. * Use piwikUrl.getSearchParam * Process comparison tables like normal tables in API.getProcessedReport. * remove some code redundancy * use new format date method * Add first working unit test for comparisons service. * Finish writing unit test for comparison service. * refactor comparisons service and fix a couple regressions * Fix more TODO items and refactoring. * Fill out more TODO. * Remove more TODO. * Fixing some tests. * another test fix * FIx some more tests. * More test fixes and regression fixes. * Do not add segments to summary rows in actions reports. * more test fixes * fix more tests * more test fixes * Fixing more tests. * Fixing more tests + debugging failing one. * Fix twig loop issue * Make sure empty compare params are not used in URL. * Remove cached request array. * Support comparison rows in multirow evolution popover and LabelFilter. * Tweak placement of some icons. * Forward current segment in reporting menu links. * Fix for split dimension view. * tweak css * Add more tests. * Add year to xlabels in evolution graph (but not xaxis tick). * applying review feedback * Apply more PR feedback * remove debugging code * tweak event docs * Fix test. * fix some test * fix a test and regression * updating tes files + fixing test * Fix regression * Fix dropdown z-index issue (or workaround really). * Fixing tests again. * Update screenshots * Fix bug and remove some debugging code * Apply review feedback. * Make sure ratio tooltips show in widgetized mode. * Fix some UI tests. * Fix tests * Fix a couple more tests.
2019-08-15Fix city archiving for cities without regions (#14731)Stefan Giehl
* Fix city archiving for cities without regions * Add city without region * Regenerate mmdb files * update exprected test files
2019-08-13Remove old unused test files (#14659)Lukas Winkler
* remove jsdoc-toolkit the last real commit seems to have been in 2011 * remove chai and mocha directories (they are now installed with npm)
2019-07-25Updates npm dependencies for screenshot testing (#14680)Stefan Giehl
* Updates npm dependencies for screenshot testing * updates expected screenshots * improve some randomly failing tests * avoid feedback popup in tests * fix integration test * updates screenshot
2019-07-15Bump lodash from 4.17.11 to 4.17.14 in /tests/lib/screenshot-testing (#14655)PatOnTheBack
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.11 to 4.17.14. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](https://github.com/lodash/lodash/compare/4.17.11...4.17.14) Signed-off-by: dependabot[bot] <support@github.com>
2019-05-17Fix realtime map ui test (#14453)3.10.0-b2diosmosis
* Make sure tooltip shows up in map. * debug travis * another test * another test * another test * another test * another test * updating screenshot * Update screenshot.
2019-05-16One Click Install UI test (#14049)diosmosis
* Add initial fixture and install script for one click install UI test. * Move matomo-package to outside matomo dir. * Create package before getting latest stable install. * More changes to fixture. * Get test releasechannel to work in latest stable version. * Handle build archives w/ matomo folders in one click update. * Fill out one click update UI test and get to pass. * Remove useless use statement. * Try cloning from HTTPS. * Add new screenshots. * Apply pr feedback and remove CoreUpdaterCode UI test. * undo submodule change * re-add line * re-add CoreUpdaterDb png files, need to keep those. * Add cron archiving test to one click update test. * use master branch of matomo-package * Make sure node_modules is accessible in screenshot testing specs. * Fix matomo-package command. * test fixes * Use correct method. * ui test fixes * Couple more test fixes. * some more test fixes * hopefully last ui test fixes * Last fix. * real last fix * Couple more random failure fixes. * Prevent from running outside of cli mode. * More aggresive check.
2019-05-16Require password confirmation before setting/removing superuser access. (#13975)diosmosis
* Require password confirmation for changing superuser access and fix issue where getSiteAccess is called w/ superuser when toggling superuser access. * apply review feedback * Allow bypassing password confirmation in certain scenarios. * Fixing tests & adding UI test. * Update submodule. * test fixes + remove return; from 2fa tests. * update submodule * Fixing tests * Couple tweaks for screenshot testing. * test fixes * Fix TwoFactorAuthUsersManager test. * More test fixes. * try to disable all transitions * More UI test fixes + disable materialize animations globally in UI tests. * 2fa ui tests now working
2019-05-15Indent actions belonging to a pageview (#14063)diosmosis
* Proof of concept for grouping actions by the page they occur in. * Add pageview to goals/ecommerce actionDetails in Live.getLastVisitsDetails. * Make count of actions to display when collapsed configurable. * Quick selector fix. * unfinished commit * Collapse multiple adjacent content items in the visitor log. * Get content collapsing to work w/ 3.x-dev changes. * Forgot to add Live config file. * Get to work w/ visitor profile and make sure last action does not have border so it looks like it correctly ends. * Fix some issues from review. * More styling tweaks. * another styling tweak * Update screenshots. * Show page refreshes and allow expanding them in new implementation. * Update some screenshots. * Make sure tooltip is replaced correctly when showing refreshes. * Another styling tweak. * Add UI test + fix page refresh issue. * Fix action group merging logic. * Fix another actions grouping issue. * Fixes for ending left border in certain edge cases. * Another UI tweak. * comparison threshold, random failure fix, update screenshots + another css tweak * more css tweaks * possible bug fix * Last couple CSS fixes. * More test fixes.
2019-05-09random failure UI test fix + update packages to get rid of github warning ↵diosmosis
(#14431) * update packages * try to fix random failure
2019-05-09Switch UI tests from phantomjs to chrome headless (#14421)Thomas Steur
* Make sure xss entries is always an array. * Update expected test files and submodule. * Regenerate broken omnifixture dump. * poc conversion to chrome headless for UI tests, single test works locally * Get single test to pass on travis & local w/ headless chrome. * Remove old diff viewer generation, and get output to look the same as before when there is a failure. * Add global timeout & get ViewDataTableTest to pass. * Convert BarGraph_spec.js. * Convert EmptySite_spec. * Update EvolutionGraph spec for chrome headless. * Convert GoalsTable test & find/replace for common changes. * Convert MeasurableManager. * Another find & replace. * Get Menus/OptOutForm to pass w/ chrome headless * Convert PeriodSelector, PieGraph & PivotByDimension UI tests. * undo unrelated debugging change * Convert QuickAccess UI tests * Converts ActionsDataTable UI tests * reset viewport after each testsuite * Converts RowEvolution UI tests * Converts Theme UI tests * Converts SiteSelector UI tests * Converts CustomVariables UI test * Converts DBStats UI test * Ignore empty responses when calling api/controller * Converts Dashboard UI tests * Converts Live UI tests * Converts SimpleUI tests * Converts Installation UI tests * Converts ImageGraph UI tests * Converts Login UI tests * Converts Marketplace UI tests * Converts Insights UI tests * Converts ReportExporting UI tests * Converts UIIntegration tests * Updates ViewDataTable UI tests * Converts CoreUpdater UI tests * Converts UsersManager UI tests * Converts Morpheus UI tests * Converts MultiSites UI tests * Fix testEnvironment.callApi handling of array parameters * Converts Overlay UI tests * Converts PrivacyManager UI tests * Converts ScheduledReports UI tests * Converts SegmentEditor UI tests * compare pixel difference in images * Converts PeriodSelector UI tests * allow a pixel difference * Converts SingleMetricView UI tests * Converts SitesManager UI tests * Converts Transitions UI tests * Converts MeasurableManager UI tests * Move Mouse out of screen after each test suite * Converts PieGraph UI tests * Ensure cursor is not shown in focused input elements * Converts VisitorMap UI tests * Converts CustomLogo UI tests * Converts BarGraph UI tests * Converts EvolutionGraph UI tests * Converts IntranetMeasurable UI tests * Converts TrackingFailures UI tests * Converts CampaignBuilder UI tests * Converts TagManagerTeaser UI tests * fix request url rewrite for changed port * Converts TwoFactorAuth UI tests * do not print full responses in logs, but size instead * improve additional style injection * use submodule branches * fix request interception * update dependencies * [TEMP] disable dangerous link checks * [TEMP] limit tests * Use puppeteer@next and make sure diffs get uploaded properly. * Use correct fs function. * Allow timeout to be specified on command line for UI tests and debug console logs. * timeout option tweak * Setup diff dir once before running tests not before each suite. * fix last commit * Update screenshots and fix some specs. * Convert some tests that were not converted during merge. * updating screenshots * Updating screenshots and fixing some tests. * more test fixes * couple more test fixes * More test fixes and plugin updates. * wait for jquery * Fix some screenshots and tests. * more test fixes * debug travis test failure * remove .only * more test fixes and updated expected files * another test fixing iteration * typo * another quick test change * more tests updates * Test fixes and & more debugging. * more debugging and test fixes * more fixes and debugging. * remove .only * Another round of fixed tests. * more debugging & fixes * more test changes * more debugging and fixes * Fixing more tests + some bug fixes. * Couple more fixes. * Couple more fixes. * Fixing tracking failures test * more fixes * Last couple fixes hopefully. * couple more test fixes * more fixes, bug fix in usersmanager, some test updates * Some more test fixes/changes. * more and more fixes * hoping for a green build * Do not compare against existing files in dashboard_spec. * more fixes, re-enabling travis * really re-enable travis * Install puppeteer on travis-ci. * more fixes * try to fix random failues * remove return * Convert some login tests I forgot and update UsersManager expected file * Fix test for primary key update * Update AddPrimaryKey.php * More test fixes + implement synchronous comparison threshold (so no resemblejs) * More wait fixes + reset token detection fix. * couple more fixes * Fix login/overlay screenshot issue & magick command running issue. * identify is the executable on travis (hopefully) + fix some random failures * Another run. * Last fix. * two more tweaks * typo
2019-02-11Remove old unused files (#14084)Lukas Winkler
* remove java files * remove (probably ) unused files
2018-11-29Make matomo.js and matomo.php the default Tracking API endpoints used (#13596)Thomas Steur
* Make matomo.js and matomo.php the default Tracking API endpoints used * few fixes * fix few tests * update matomo php tracker in composer * make sure to record install version * do not overwrite ever install version * trying to fix test * more tweaks and fix tests * prefer matomo endpoint in the ui, fix some tests * file was still needed * apply review feedback * fix ui tests
2018-11-21Fix build (#13741)diosmosis
* Fix link checking function if jQuery is not on the page and check for errors. * fixing tests * Whitelist more js code for dangerous link check.
2018-11-19Assume `javascript:void(0);` as safe link in tests (#13722)Stefan Giehl
* Assume javascript:void(0); as safe link * update some more UI files
2018-11-13Regenerate OmniFixture dump w/ more xss payloads (#13556)diosmosis
* Buffing xss testing system. * More testing changes. * Finish adding more xss test data. * Update ui-test.php file. * Use DI\add in test container override. * Update OmniFixture. * Get fixture to setup properly. * Make xss sanity check work w/ persist fixture data option. * Another sanity check tweak. * Trying to debug xss sanity check. * removing duplicates * Fix xss testing JS. * Escape widget category text. * deal w/ angular input in goal name * Ensure privacy manager links are safe and add automated test for dangerous links to UI tests. * Create dangerous link method in xsstesting class. * Make xss test failures a bit easier to debug and escape metric documentation for angular. * Tweak quickaccess test. * Try to get pviot by dimension test to pass. * Tweak QuickAccess test and try to get xss reports to show. * Fix exception message. * Tweaks to fake xss report (cannot currently be displayed). * Updating screenshots. * In check for dangerous links test allow empty links that use dangerous prefix. * fix a cou0le more tests. * update more screenshots * Update a couple more screenshots. * Updated screenshot. * update screenshots * update two more screenshots * Use ng-bind-html to sanitize report documentation which can potentially have HTML. * update screenshots
2018-09-06Add [tests] config option to enable logging in tests. (#13335)diosmosis
* Add [tests] config option to enable logging in tests. * Allow tests:run/tests:run-ui commands to enable logging for individual runs + during tests only log to file. * Remove Fixture field * fix failing test * fixing build * Fix another failure. * Fix an other test.
2018-08-09Add notification when report w/ segment has no data, but segment is ↵3.6.0-b4diosmosis
unprocessed (#12823) * When a report has no data, check if it is for an unprocessed segment and display an explanatory notification. * Remove transient notifications on reporting page change, allow datatable views to add notifications, use to display unprocessed segment message. * Update changelog. * Internationalize unprocessed segment message. * Parse notification divs in dashboardWidget.js when setting widget content. * Tweak message. * Change PR to use different approach: throw exception when no archives found and segment is used, then detect exception in new event. * Update changelog + document new event. * Unfinished review changes * more review fixes * Do not show notification w/ custom segments. * apply pr review * Apply review. * undo escaping since it was not needed & get test to pass * Different strategy + new test. * Fix tests. * Update two expected screenshots.
2018-08-06Updates omnifixture (#13249)Stefan Giehl
* updates geoip2 test db * updates omnifixture * update ui files
2018-06-28Remove executable bit on most files (#13038)Adrien Crivelli
Only the files declaring a shebang have their execution bit set. Everything else is not executable to avoid possible security issues
2018-06-14Remove usage of synchronous ajax requests (#12546)Stefan Giehl
* Do not use sync ajax requests * adds deprecation comments * convert some methods to be fully async * adds minimum waittime after page load in ui tests * improve wait times
2018-06-01Fix some UI tests, including random failure + allow --piwik-domain use in ↵diosmosis
tests:run-ui (#13027) * Forward --piwik-domain to sub-commands from tests:run-ui. * temp commit debugging * Predictable screenshots for realtime map in dashboard. * Fix translation regression. * Update UI test case & screenshots. * Remove it.only * update screenshot * removes unused use statements
2018-05-20Allow use of GeoLite2-ASN database as ISP database (#12874)Stefan Giehl
* Adds possibility to use GeoLite2-ASN database as ISP database * Adds some tests for GeoIP2 files * fix tests * fix check for GeoIp2 provider