Testing
Quality Assurance (QA): Test our release packages. Install them from scratch, try updates from previous versions, make sure everything is working, check if the upgrader works along the different (Repo-)Versions. The chain breaks at the weakest link.
|
wackowiki-6.1.26.zip[link3] (2.3 MiB) Please download the program, take it for a test-drive and tell us what you think. BETA versions are always for testing purposes only. Development version Keep in mind, that this is still an alpha version - so be advised to not use it for production data! ¯\_(ツ)_/¯ |
1. Tools
- XAMPP[link6]
- PHPUnit[link7]
- https://www.codacy.com
- http://xdebug.org
- https://phpstan.org
- 🦊 Firefox
- Web Developer[link8]
- Quick Locale Switcher[link9]
- User Agent Switcher[link10]
- uMatrix[link11]
- Livemarks[link12] - FF 64 removed the RSS reader!
- Laboratory (Content Security Policy / CSP Toolkit)[link13]
- Lynx[link14] - Do the test, all essential functionality must work WHITHOUT JavaScript.
-
lynx https://wackowiki.org/doc/Doc/English/Markup
-
2. Testing
- Test new patches - try them out and see what breaks
- Do performance tests - compare versions & settings
- Do security audits
- Do benchmarks
- Do localization checks
- Check standards / spec compliance - SQL, XML, APIs, ...
- https://developers.google.com/speed/pagespeed/insights/
- https://securityheaders.io
- HTML validator[link15]
- CSS validator[link16]
- Feed validator[link17]
- https://web.dev/measure
- WAVE – Online accessibility validator[link18]
- http://jshint.com
- https://www.google.com/webmast[...]ols/mobile-friendly/[link19]
- http://www.webpagetest.org - Test a website's performance
- W3C Internationalization Checker[link20]
- REDbot[link21] - lint for HTTP resources; it tests protocol correctness, cacheability, content negotiation and more.
- https://github.com/mozilla/readability - test with firefox reading mode
- Test integration - does the new version work with all scripts & dbs?
3. Debugging
- check error logs
-
\apache\logs\error.log
-
\php\logs\php_error_log
-
3.1. Debug options
3.1.1. Primary config
config/config.php- set
sql_mode
in primary config to2
to enable SQL Session Strict mode'sql_mode' => '2',
3.1.2. Secondary config
config table (Admin Panel -> System)
- set '
debug
' in secondary config to3
- set
cache
in secondary config to0
- set
cache_sql
in secondary config to0
3.1.3. Constants
config/constants.php- set
DB_ERROR_MODE
in config/constants.phpconst DB_ERROR_MODE = 1;
- Warning
- Exception (Fatal error)
- set
PHP_ERROR_REPORTING
in config/constants.phpconst PHP_ERROR_REPORTING = 6;
- Fatal error
- Parse error
- Warning
- Notice
3.2. php_error_log
[19-May-2022 11:31:23 Mittelerde/Auenland] PHP Deprecated: preg_match_all(): Passing null to parameter #2 ($subject) of type string is deprecated in /home/hobbit/git/wackowiki/src/formatter/class/typografica.php on line 134 [19-May-2022 11:31:23 Mittelerde/Auenland] PHP Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/hobbit/git/wackowiki/src/formatter/class/typografica.php on line 135
3.3. Debug functions
- to write a parameter in the debug log
-
Ut::dbg('debug_variable', $parameter);
-
- add debug output to DEBUG file and popup-window in browser
-
Diag::dbg($parameter);
- to highlight the debug output in the console add
'[BLUE|GOLD|ORANGE|RED]'
as the first argument- e.g.
Diag::dbg('GOLD', $parameter);
-
Diag::dbg('GOLD', 'Message set:', $lang, $name, @$this->user_lang, @$this->page_lang, @$this->notify_lang);
- e.g.
-
3.3.1. Example
Diag::dbg('preprocess', $parser->preprocess ? 'true' : 'false');
; -0.2427 formatter/wacko.php:50 preprocess false -0.2365 formatter/wacko.php:50 preprocess true -0.0547 formatter/wacko.php:50 preprocess false 0.0332 formatter/wacko.php:50 preprocess false
3.3.2. File permissions
In both cases it writes the$parameter
to the log in the main directory src/DEBUG
when the config debug
is enabled. Be aware the log isn't emptied automatically. Ensure that the file
src/DEBUG
can be created and is writable.touch DEBUG chmod 0664 DEBUG
- [link1] https://wackowiki.org/doc/Dev/TodoList
- [link2] https://wackowiki.org/doc/Org/Tools/Hosting/TestServer
- [link3] https://downloads.sourceforge.net/wackowiki/wackowiki-6.1.26.zip
- [link4] https://bitbucket.org/wackowiki/wackowiki-dev/get/tip.tar.gz
- [link5] https://wackowiki.org/doc/Org/Tools/Repository
- [link6] http://www.apachefriends.org
- [link7] http://www.phpunit.de/
- [link8] http://chrispederick.com/work/web-developer/
- [link9] https://addons.mozilla.org/de/firefox/addon/quick-locale-switcher2/
- [link10] https://addons.mozilla.org/de/firefox/addon/uaswitcher/
- [link11] https://addons.mozilla.org/en-US/firefox/addon/umatrix/
- [link12] https://addons.mozilla.org/de/firefox/addon/livemarks/
- [link13] https://addons.mozilla.org/en-US/firefox/addon/laboratory-by-mozilla/
- [link14] https://lynx.invisible-island.net/
- [link15] http://validator.w3.org/nu/
- [link16] https://jigsaw.w3.org/css-validator/
- [link17] https://validator.w3.org/feed/
- [link18] http://wave.webaim.org/
- [link19] https://www.google.com/webmasters/tools/mobile-friendly/
- [link20] https://validator.w3.org/i18n-checker/
- [link21] https://redbot.org