Page Menu
Home
In-Portal Phabricator
Search
Configure Global Search
Log In
Files
F803844
D451.id1163.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Wed, Feb 26, 8:59 AM
Size
57 KB
Mime Type
text/x-diff
Expires
Thu, Feb 27, 8:59 AM (10 h, 43 m)
Engine
blob
Format
Raw Data
Handle
576567
Attached To
D451: INP-1827 - Connect a testing framework
D451.id1163.diff
View Options
Index: composer.json
===================================================================
--- composer.json
+++ composer.json
@@ -1,21 +1,22 @@
{
- "name": "In-Portal",
+ "name": "intechnic/in-portal",
"require": {
- "php": ">=5.3.7",
+ "php": ">=5.4.0",
"paragonie/random_compat": "^2.0",
"symfony/polyfill-php55": "^1.19",
"symfony/polyfill-php56": "^1.19"
},
"require-dev": {
+ "behat/mink": "^1.7",
"aik099/phpunit-mink": "^2.2",
+ "yoast/phpunit-polyfills": "^1.1",
"qa-tools/qa-tools": "^1.2",
- "aik099/coding-standard": "dev-in-portal",
-
- "behat/mink": "^1.7"
+ "phpspec/prophecy": "^1.10",
+ "aik099/coding-standard": "dev-in-portal"
},
"config": {
"platform": {
- "php": "5.3.7"
+ "php": "5.4.0"
}
}
}
Index: composer.lock
===================================================================
--- composer.lock
+++ composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "ef20f3d542075e2d792fba4a7d3379c2",
+ "content-hash": "982948269c77150f85ea5efd93aef365",
"packages": [
{
"name": "ircmaxell/password-compat",
@@ -46,27 +46,31 @@
"hashing",
"password"
],
+ "support": {
+ "issues": "https://github.com/ircmaxell/password_compat/issues",
+ "source": "https://github.com/ircmaxell/password_compat/tree/v1.0"
+ },
"time": "2014-11-20T16:49:30+00:00"
},
{
"name": "paragonie/random_compat",
- "version": "v2.0.19",
+ "version": "v2.0.21",
"source": {
"type": "git",
"url": "https://github.com/paragonie/random_compat.git",
- "reference": "446fc9faa5c2a9ddf65eb7121c0af7e857295241"
+ "reference": "96c132c7f2f7bc3230723b66e89f8f150b29d5ae"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/paragonie/random_compat/zipball/446fc9faa5c2a9ddf65eb7121c0af7e857295241",
- "reference": "446fc9faa5c2a9ddf65eb7121c0af7e857295241",
+ "url": "https://api.github.com/repos/paragonie/random_compat/zipball/96c132c7f2f7bc3230723b66e89f8f150b29d5ae",
+ "reference": "96c132c7f2f7bc3230723b66e89f8f150b29d5ae",
"shasum": ""
},
"require": {
"php": ">=5.2.0"
},
"require-dev": {
- "phpunit/phpunit": "4.*|5.*"
+ "phpunit/phpunit": "*"
},
"suggest": {
"ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes."
@@ -95,7 +99,12 @@
"pseudorandom",
"random"
],
- "time": "2020-10-15T10:06:57+00:00"
+ "support": {
+ "email": "info@paragonie.com",
+ "issues": "https://github.com/paragonie/random_compat/issues",
+ "source": "https://github.com/paragonie/random_compat"
+ },
+ "time": "2022-02-16T17:07:03+00:00"
},
{
"name": "symfony/polyfill-php55",
@@ -126,12 +135,12 @@
}
},
"autoload": {
- "psr-4": {
- "Symfony\\Polyfill\\Php55\\": ""
- },
"files": [
"bootstrap.php"
- ]
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Php55\\": ""
+ }
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -155,6 +164,9 @@
"portable",
"shim"
],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-php55/tree/v1.19.0"
+ },
"funding": [
{
"url": "https://symfony.com/sponsor",
@@ -200,12 +212,12 @@
}
},
"autoload": {
- "psr-4": {
- "Symfony\\Polyfill\\Php56\\": ""
- },
"files": [
"bootstrap.php"
- ]
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Php56\\": ""
+ }
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -229,6 +241,9 @@
"portable",
"shim"
],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-php56/tree/v1.19.0"
+ },
"funding": [
{
"url": "https://symfony.com/sponsor",
@@ -299,6 +314,9 @@
"polyfill",
"shim"
],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-util/tree/v1.19.0"
+ },
"funding": [
{
"url": "https://symfony.com/sponsor",
@@ -323,16 +341,17 @@
"source": {
"type": "git",
"url": "https://github.com/aik099/CodingStandard.git",
- "reference": "3b6de0c179b7da4c2ea1763f9f5c3961268c7d6f"
+ "reference": "26b67b43b3cb4d57a68a472170bf6fab07334c18"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/aik099/CodingStandard/zipball/3b6de0c179b7da4c2ea1763f9f5c3961268c7d6f",
- "reference": "3b6de0c179b7da4c2ea1763f9f5c3961268c7d6f",
+ "url": "https://api.github.com/repos/aik099/CodingStandard/zipball/26b67b43b3cb4d57a68a472170bf6fab07334c18",
+ "reference": "26b67b43b3cb4d57a68a472170bf6fab07334c18",
"shasum": ""
},
"require-dev": {
- "squizlabs/php_codesniffer": "^3.0"
+ "squizlabs/php_codesniffer": "^3.0",
+ "yoast/phpunit-polyfills": "^1.0"
},
"type": "library",
"extra": {
@@ -355,7 +374,11 @@
"PHP_CodeSniffer",
"codesniffer"
],
- "time": "2018-12-09T10:49:24+00:00"
+ "support": {
+ "issues": "https://github.com/aik099/CodingStandard/issues",
+ "source": "https://github.com/aik099/CodingStandard/tree/in-portal"
+ },
+ "time": "2021-11-07T17:05:54+00:00"
},
{
"name": "aik099/phpunit-mink",
@@ -415,39 +438,47 @@
"selenium",
"tests"
],
+ "support": {
+ "issues": "https://github.com/minkphp/phpunit-mink/issues",
+ "source": "https://github.com/minkphp/phpunit-mink/tree/v2.2.0"
+ },
"time": "2016-06-26T09:07:47+00:00"
},
{
"name": "behat/mink",
- "version": "v1.7.1",
+ "version": "v1.9.0",
"source": {
"type": "git",
"url": "https://github.com/minkphp/Mink.git",
- "reference": "e6930b9c74693dff7f4e58577e1b1743399f3ff9"
+ "reference": "e35f4695de8800fc776af34ebf665ad58ebdd996"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/minkphp/Mink/zipball/e6930b9c74693dff7f4e58577e1b1743399f3ff9",
- "reference": "e6930b9c74693dff7f4e58577e1b1743399f3ff9",
+ "url": "https://api.github.com/repos/minkphp/Mink/zipball/e35f4695de8800fc776af34ebf665ad58ebdd996",
+ "reference": "e35f4695de8800fc776af34ebf665ad58ebdd996",
"shasum": ""
},
"require": {
- "php": ">=5.3.1",
- "symfony/css-selector": "~2.1|~3.0"
+ "php": ">=5.4",
+ "symfony/css-selector": "^2.7|^3.0|^4.0|^5.0"
},
"require-dev": {
- "symfony/phpunit-bridge": "~2.7|~3.0"
+ "phpunit/phpunit": "^4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5 || ^9.5",
+ "symfony/debug": "^2.7|^3.0|^4.0|^5.0",
+ "symfony/phpunit-bridge": "^3.4.38 || ^4.4 || ^5.0.5",
+ "yoast/phpunit-polyfills": "^1.0"
},
"suggest": {
"behat/mink-browserkit-driver": "extremely fast headless driver for Symfony\\Kernel-based apps (Sf2, Silex)",
"behat/mink-goutte-driver": "fast headless driver for any app without JS emulation",
"behat/mink-selenium2-driver": "slow, but JS-enabled driver for any app (requires Selenium2)",
- "behat/mink-zombie-driver": "fast and JS-enabled headless driver for any app (requires node.js)"
+ "behat/mink-zombie-driver": "fast and JS-enabled headless driver for any app (requires node.js)",
+ "dmore/chrome-mink-driver": "fast and JS-enabled driver for any app (requires chromium or google chrome)"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "1.7.x-dev"
+ "dev-master": "1.x-dev"
}
},
"autoload": {
@@ -467,40 +498,44 @@
}
],
"description": "Browser controller/emulator abstraction for PHP",
- "homepage": "http://mink.behat.org/",
+ "homepage": "https://mink.behat.org/",
"keywords": [
"browser",
"testing",
"web"
],
- "time": "2016-03-05T08:26:18+00:00"
+ "support": {
+ "issues": "https://github.com/minkphp/Mink/issues",
+ "source": "https://github.com/minkphp/Mink/tree/v1.9.0"
+ },
+ "time": "2021-10-11T11:58:47+00:00"
},
{
"name": "behat/mink-selenium2-driver",
- "version": "v1.3.1",
+ "version": "v1.5.0",
"source": {
"type": "git",
"url": "https://github.com/minkphp/MinkSelenium2Driver.git",
- "reference": "473a9f3ebe0c134ee1e623ce8a9c852832020288"
+ "reference": "0dee8cceed7e198bf130b4af0fab0ffab6dab47f"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/minkphp/MinkSelenium2Driver/zipball/473a9f3ebe0c134ee1e623ce8a9c852832020288",
- "reference": "473a9f3ebe0c134ee1e623ce8a9c852832020288",
+ "url": "https://api.github.com/repos/minkphp/MinkSelenium2Driver/zipball/0dee8cceed7e198bf130b4af0fab0ffab6dab47f",
+ "reference": "0dee8cceed7e198bf130b4af0fab0ffab6dab47f",
"shasum": ""
},
"require": {
"behat/mink": "~1.7@dev",
"instaclick/php-webdriver": "~1.1",
- "php": ">=5.3.1"
+ "php": ">=5.4"
},
"require-dev": {
- "symfony/phpunit-bridge": "~2.7"
+ "mink/driver-testsuite": "dev-master"
},
"type": "mink-driver",
"extra": {
"branch-alias": {
- "dev-master": "1.3.x-dev"
+ "dev-master": "1.x-dev"
}
},
"autoload": {
@@ -514,18 +549,18 @@
],
"authors": [
{
- "name": "Konstantin Kudryashov",
- "email": "ever.zet@gmail.com",
- "homepage": "http://everzet.com"
- },
- {
"name": "Pete Otaqui",
"email": "pete@otaqui.com",
"homepage": "https://github.com/pete-otaqui"
+ },
+ {
+ "name": "Konstantin Kudryashov",
+ "email": "ever.zet@gmail.com",
+ "homepage": "http://everzet.com"
}
],
"description": "Selenium2 (WebDriver) driver for Mink framework",
- "homepage": "http://mink.behat.org/",
+ "homepage": "https://mink.behat.org/",
"keywords": [
"ajax",
"browser",
@@ -534,7 +569,11 @@
"testing",
"webdriver"
],
- "time": "2016-03-05T09:10:18+00:00"
+ "support": {
+ "issues": "https://github.com/minkphp/MinkSelenium2Driver/issues",
+ "source": "https://github.com/minkphp/MinkSelenium2Driver/tree/v1.5.0"
+ },
+ "time": "2021-10-12T16:01:47+00:00"
},
{
"name": "doctrine/instantiator",
@@ -588,20 +627,38 @@
"constructor",
"instantiate"
],
+ "support": {
+ "issues": "https://github.com/doctrine/instantiator/issues",
+ "source": "https://github.com/doctrine/instantiator/tree/1.0.5"
+ },
+ "funding": [
+ {
+ "url": "https://www.doctrine-project.org/sponsorship.html",
+ "type": "custom"
+ },
+ {
+ "url": "https://www.patreon.com/phpdoctrine",
+ "type": "patreon"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator",
+ "type": "tidelift"
+ }
+ ],
"time": "2015-06-14T21:17:01+00:00"
},
{
"name": "instaclick/php-webdriver",
- "version": "1.4.5",
+ "version": "1.4.16",
"source": {
"type": "git",
"url": "https://github.com/instaclick/php-webdriver.git",
- "reference": "6fa959452e774dcaed543faad3a9d1a37d803327"
+ "reference": "a39a1f6dc0f4ddd8b2438fa5eb1f67755730d606"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/instaclick/php-webdriver/zipball/6fa959452e774dcaed543faad3a9d1a37d803327",
- "reference": "6fa959452e774dcaed543faad3a9d1a37d803327",
+ "url": "https://api.github.com/repos/instaclick/php-webdriver/zipball/a39a1f6dc0f4ddd8b2438fa5eb1f67755730d606",
+ "reference": "a39a1f6dc0f4ddd8b2438fa5eb1f67755730d606",
"shasum": ""
},
"require": {
@@ -609,8 +666,8 @@
"php": ">=5.3.2"
},
"require-dev": {
- "phpunit/phpunit": "^4.8",
- "satooshi/php-coveralls": "^1.0||^2.0"
+ "phpunit/phpunit": "^8.5 || ^9.5",
+ "satooshi/php-coveralls": "^1.0 || ^2.0"
},
"type": "library",
"extra": {
@@ -647,20 +704,24 @@
"webdriver",
"webtest"
],
- "time": "2017-06-30T04:02:48+00:00"
+ "support": {
+ "issues": "https://github.com/instaclick/php-webdriver/issues",
+ "source": "https://github.com/instaclick/php-webdriver/tree/1.4.16"
+ },
+ "time": "2022-10-28T13:30:35+00:00"
},
{
"name": "mindplay/annotations",
- "version": "1.3.0",
+ "version": "1.3.3",
"source": {
"type": "git",
"url": "https://github.com/php-annotations/php-annotations.git",
- "reference": "a5830fb63f822cb72c4bf6172955fd05986557c6"
+ "reference": "d314832b338b88299c4108361c858b0590798d2c"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/php-annotations/php-annotations/zipball/a5830fb63f822cb72c4bf6172955fd05986557c6",
- "reference": "a5830fb63f822cb72c4bf6172955fd05986557c6",
+ "url": "https://api.github.com/repos/php-annotations/php-annotations/zipball/d314832b338b88299c4108361c858b0590798d2c",
+ "reference": "d314832b338b88299c4108361c858b0590798d2c",
"shasum": ""
},
"require": {
@@ -668,12 +729,12 @@
},
"require-dev": {
"phpunit/php-code-coverage": "~1.2.1",
- "phpunit/php-file-iterator": ">=1.3.0@stable"
+ "phpunit/php-file-iterator": ">=1.3.0@stable <2.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "1.2.x-dev"
+ "dev-master": "1.3.x-dev"
}
},
"autoload": {
@@ -697,7 +758,11 @@
"annotations",
"framework"
],
- "time": "2016-02-14T20:09:40+00:00"
+ "support": {
+ "issues": "https://github.com/php-annotations/php-annotations/issues",
+ "source": "https://github.com/php-annotations/php-annotations/tree/1.3.3"
+ },
+ "time": "2022-07-16T15:11:03+00:00"
},
{
"name": "phpdocumentor/reflection-docblock",
@@ -746,42 +811,46 @@
"email": "mike.vanriel@naenius.com"
}
],
+ "support": {
+ "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues",
+ "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/release/2.x"
+ },
"time": "2016-01-25T08:17:30+00:00"
},
{
"name": "phpspec/prophecy",
- "version": "1.8.0",
+ "version": "v1.10.3",
"source": {
"type": "git",
"url": "https://github.com/phpspec/prophecy.git",
- "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06"
+ "reference": "451c3cd1418cf640de218914901e51b064abb093"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4ba436b55987b4bf311cb7c6ba82aa528aac0a06",
- "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06",
+ "url": "https://api.github.com/repos/phpspec/prophecy/zipball/451c3cd1418cf640de218914901e51b064abb093",
+ "reference": "451c3cd1418cf640de218914901e51b064abb093",
"shasum": ""
},
"require": {
"doctrine/instantiator": "^1.0.2",
"php": "^5.3|^7.0",
- "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0",
- "sebastian/comparator": "^1.1|^2.0|^3.0",
- "sebastian/recursion-context": "^1.0|^2.0|^3.0"
+ "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0",
+ "sebastian/comparator": "^1.2.3|^2.0|^3.0|^4.0",
+ "sebastian/recursion-context": "^1.0|^2.0|^3.0|^4.0"
},
"require-dev": {
- "phpspec/phpspec": "^2.5|^3.2",
+ "phpspec/phpspec": "^2.5 || ^3.2",
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "1.8.x-dev"
+ "dev-master": "1.10.x-dev"
}
},
"autoload": {
- "psr-0": {
- "Prophecy\\": "src/"
+ "psr-4": {
+ "Prophecy\\": "src/Prophecy"
}
},
"notification-url": "https://packagist.org/downloads/",
@@ -809,7 +878,11 @@
"spy",
"stub"
],
- "time": "2018-08-05T17:53:17+00:00"
+ "support": {
+ "issues": "https://github.com/phpspec/prophecy/issues",
+ "source": "https://github.com/phpspec/prophecy/tree/v1.10.3"
+ },
+ "time": "2020-03-05T15:02:03+00:00"
},
{
"name": "phpunit/php-code-coverage",
@@ -871,6 +944,11 @@
"testing",
"xunit"
],
+ "support": {
+ "irc": "irc://irc.freenode.net/phpunit",
+ "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
+ "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/2.2"
+ },
"time": "2015-10-06T15:47:00+00:00"
},
{
@@ -918,6 +996,11 @@
"filesystem",
"iterator"
],
+ "support": {
+ "irc": "irc://irc.freenode.net/phpunit",
+ "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues",
+ "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/1.4.5"
+ },
"time": "2017-11-27T13:52:08+00:00"
},
{
@@ -959,6 +1042,10 @@
"keywords": [
"template"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-text-template/issues",
+ "source": "https://github.com/sebastianbergmann/php-text-template/tree/1.2.1"
+ },
"time": "2015-06-21T13:50:34+00:00"
},
{
@@ -1008,6 +1095,10 @@
"keywords": [
"timer"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-timer/issues",
+ "source": "https://github.com/sebastianbergmann/php-timer/tree/master"
+ },
"time": "2017-02-26T11:10:40+00:00"
},
{
@@ -1057,6 +1148,10 @@
"keywords": [
"tokenizer"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/php-token-stream/issues",
+ "source": "https://github.com/sebastianbergmann/php-token-stream/tree/1.4"
+ },
"abandoned": true,
"time": "2017-12-04T08:55:13+00:00"
},
@@ -1130,6 +1225,10 @@
"testing",
"xunit"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/phpunit/issues",
+ "source": "https://github.com/sebastianbergmann/phpunit/tree/4.8.36"
+ },
"time": "2017-06-21T08:07:12+00:00"
},
{
@@ -1186,6 +1285,11 @@
"mock",
"xunit"
],
+ "support": {
+ "irc": "irc://irc.freenode.net/phpunit",
+ "issues": "https://github.com/sebastianbergmann/phpunit-mock-objects/issues",
+ "source": "https://github.com/sebastianbergmann/phpunit-mock-objects/tree/2.3"
+ },
"abandoned": true,
"time": "2015-10-02T06:51:40+00:00"
},
@@ -1237,6 +1341,10 @@
"container",
"dependency injection"
],
+ "support": {
+ "issues": "https://github.com/silexphp/Pimple/issues",
+ "source": "https://github.com/silexphp/Pimple/tree/master"
+ },
"time": "2018-01-21T07:42:36+00:00"
},
{
@@ -1286,6 +1394,10 @@
"container-interop",
"psr"
],
+ "support": {
+ "issues": "https://github.com/php-fig/container/issues",
+ "source": "https://github.com/php-fig/container/tree/master"
+ },
"time": "2017-02-14T16:28:37+00:00"
},
{
@@ -1360,6 +1472,10 @@
"phpunit",
"tests"
],
+ "support": {
+ "issues": "https://github.com/qa-tools/qa-tools/issues",
+ "source": "https://github.com/qa-tools/qa-tools/tree/master"
+ },
"time": "2016-07-06T11:31:04+00:00"
},
{
@@ -1424,6 +1540,10 @@
"compare",
"equality"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/comparator/issues",
+ "source": "https://github.com/sebastianbergmann/comparator/tree/1.2"
+ },
"time": "2017-01-29T09:50:25+00:00"
},
{
@@ -1476,6 +1596,10 @@
"keywords": [
"diff"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/diff/issues",
+ "source": "https://github.com/sebastianbergmann/diff/tree/1.4"
+ },
"time": "2017-05-22T07:24:03+00:00"
},
{
@@ -1526,6 +1650,10 @@
"environment",
"hhvm"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/environment/issues",
+ "source": "https://github.com/sebastianbergmann/environment/tree/1.3"
+ },
"time": "2016-08-18T05:49:44+00:00"
},
{
@@ -1593,6 +1721,10 @@
"export",
"exporter"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/exporter/issues",
+ "source": "https://github.com/sebastianbergmann/exporter/tree/master"
+ },
"time": "2016-06-17T09:04:28+00:00"
},
{
@@ -1644,6 +1776,10 @@
"keywords": [
"global state"
],
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/global-state/issues",
+ "source": "https://github.com/sebastianbergmann/global-state/tree/1.1.1"
+ },
"time": "2015-10-12T03:26:01+00:00"
},
{
@@ -1697,6 +1833,10 @@
],
"description": "Provides functionality to recursively process PHP variables",
"homepage": "http://www.github.com/sebastianbergmann/recursion-context",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/recursion-context/issues",
+ "source": "https://github.com/sebastianbergmann/recursion-context/tree/master"
+ },
"time": "2016-10-03T07:41:43+00:00"
},
{
@@ -1732,39 +1872,42 @@
],
"description": "Library that helps with managing the version number of Git-hosted PHP projects",
"homepage": "https://github.com/sebastianbergmann/version",
+ "support": {
+ "issues": "https://github.com/sebastianbergmann/version/issues",
+ "source": "https://github.com/sebastianbergmann/version/tree/1.0.6"
+ },
"time": "2015-06-21T13:59:46+00:00"
},
{
"name": "symfony/css-selector",
- "version": "v2.6.13",
- "target-dir": "Symfony/Component/CssSelector",
+ "version": "v2.8.52",
"source": {
"type": "git",
"url": "https://github.com/symfony/css-selector.git",
- "reference": "560e446b93883050a5874908652e8e912e8cbe44"
+ "reference": "7b1692e418d7ccac24c373528453bc90e42797de"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/css-selector/zipball/560e446b93883050a5874908652e8e912e8cbe44",
- "reference": "560e446b93883050a5874908652e8e912e8cbe44",
+ "url": "https://api.github.com/repos/symfony/css-selector/zipball/7b1692e418d7ccac24c373528453bc90e42797de",
+ "reference": "7b1692e418d7ccac24c373528453bc90e42797de",
"shasum": ""
},
"require": {
- "php": ">=5.3.3"
- },
- "require-dev": {
- "symfony/phpunit-bridge": "~2.7"
+ "php": ">=5.3.9"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "2.6-dev"
+ "dev-master": "2.8-dev"
}
},
"autoload": {
- "psr-0": {
+ "psr-4": {
"Symfony\\Component\\CssSelector\\": ""
- }
+ },
+ "exclude-from-classmap": [
+ "/Tests/"
+ ]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -1772,47 +1915,48 @@
],
"authors": [
{
- "name": "Jean-François Simon",
- "email": "jeanfrancois.simon@sensiolabs.com"
- },
- {
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
+ "name": "Jean-François Simon",
+ "email": "jeanfrancois.simon@sensiolabs.com"
+ },
+ {
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony CssSelector Component",
"homepage": "https://symfony.com",
- "time": "2015-05-15T13:32:45+00:00"
+ "support": {
+ "source": "https://github.com/symfony/css-selector/tree/v2.8.52"
+ },
+ "time": "2018-11-11T11:18:13+00:00"
},
{
"name": "symfony/event-dispatcher",
- "version": "v2.6.13",
- "target-dir": "Symfony/Component/EventDispatcher",
+ "version": "v2.8.52",
"source": {
"type": "git",
"url": "https://github.com/symfony/event-dispatcher.git",
- "reference": "672593bc4b0043a0acf91903bb75a1c82d8f2e02"
+ "reference": "a77e974a5fecb4398833b0709210e3d5e334ffb0"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/672593bc4b0043a0acf91903bb75a1c82d8f2e02",
- "reference": "672593bc4b0043a0acf91903bb75a1c82d8f2e02",
+ "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/a77e974a5fecb4398833b0709210e3d5e334ffb0",
+ "reference": "a77e974a5fecb4398833b0709210e3d5e334ffb0",
"shasum": ""
},
"require": {
- "php": ">=5.3.3"
+ "php": ">=5.3.9"
},
"require-dev": {
"psr/log": "~1.0",
- "symfony/config": "~2.0,>=2.0.5",
- "symfony/dependency-injection": "~2.6",
- "symfony/expression-language": "~2.6",
- "symfony/phpunit-bridge": "~2.7",
- "symfony/stopwatch": "~2.3"
+ "symfony/config": "^2.0.5|~3.0.0",
+ "symfony/dependency-injection": "~2.6|~3.0.0",
+ "symfony/expression-language": "~2.6|~3.0.0",
+ "symfony/stopwatch": "~2.3|~3.0.0"
},
"suggest": {
"symfony/dependency-injection": "",
@@ -1821,13 +1965,16 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "2.6-dev"
+ "dev-master": "2.8-dev"
}
},
"autoload": {
- "psr-0": {
+ "psr-4": {
"Symfony\\Component\\EventDispatcher\\": ""
- }
+ },
+ "exclude-from-classmap": [
+ "/Tests/"
+ ]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -1845,40 +1992,122 @@
],
"description": "Symfony EventDispatcher Component",
"homepage": "https://symfony.com",
- "time": "2015-05-02T15:18:45+00:00"
+ "support": {
+ "source": "https://github.com/symfony/event-dispatcher/tree/v2.8.50"
+ },
+ "time": "2018-11-21T14:20:20+00:00"
},
{
- "name": "symfony/yaml",
- "version": "v2.6.13",
- "target-dir": "Symfony/Component/Yaml",
+ "name": "symfony/polyfill-ctype",
+ "version": "v1.19.0",
"source": {
"type": "git",
- "url": "https://github.com/symfony/yaml.git",
- "reference": "c044d1744b8e91aaaa0d9bac683ab87ec7cbf359"
+ "url": "https://github.com/symfony/polyfill-ctype.git",
+ "reference": "aed596913b70fae57be53d86faa2e9ef85a2297b"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/yaml/zipball/c044d1744b8e91aaaa0d9bac683ab87ec7cbf359",
- "reference": "c044d1744b8e91aaaa0d9bac683ab87ec7cbf359",
+ "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/aed596913b70fae57be53d86faa2e9ef85a2297b",
+ "reference": "aed596913b70fae57be53d86faa2e9ef85a2297b",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
- "require-dev": {
- "symfony/phpunit-bridge": "~2.7"
+ "suggest": {
+ "ext-ctype": "For best performance"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "2.6-dev"
+ "dev-main": "1.19-dev"
+ },
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
}
},
"autoload": {
- "psr-0": {
- "Symfony\\Component\\Yaml\\": ""
+ "files": [
+ "bootstrap.php"
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Ctype\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Gert de Pagter",
+ "email": "BackEndTea@gmail.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "Symfony polyfill for ctype functions",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "compatibility",
+ "ctype",
+ "polyfill",
+ "portable"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-ctype/tree/v1.19.0"
+ },
+ "funding": [
+ {
+ "url": "https://symfony.com/sponsor",
+ "type": "custom"
+ },
+ {
+ "url": "https://github.com/fabpot",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2020-10-23T09:01:57+00:00"
+ },
+ {
+ "name": "symfony/yaml",
+ "version": "v2.8.52",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/yaml.git",
+ "reference": "02c1859112aa779d9ab394ae4f3381911d84052b"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/yaml/zipball/02c1859112aa779d9ab394ae4f3381911d84052b",
+ "reference": "02c1859112aa779d9ab394ae4f3381911d84052b",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.9",
+ "symfony/polyfill-ctype": "~1.8"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.8-dev"
}
},
+ "autoload": {
+ "psr-4": {
+ "Symfony\\Component\\Yaml\\": ""
+ },
+ "exclude-from-classmap": [
+ "/Tests/"
+ ]
+ },
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
@@ -1895,7 +2124,70 @@
],
"description": "Symfony Yaml Component",
"homepage": "https://symfony.com",
- "time": "2015-07-26T08:59:42+00:00"
+ "support": {
+ "source": "https://github.com/symfony/yaml/tree/v2.8.52"
+ },
+ "time": "2018-11-11T11:18:13+00:00"
+ },
+ {
+ "name": "yoast/phpunit-polyfills",
+ "version": "1.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Yoast/PHPUnit-Polyfills.git",
+ "reference": "224e4a1329c03d8bad520e3fc4ec980034a4b212"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Yoast/PHPUnit-Polyfills/zipball/224e4a1329c03d8bad520e3fc4ec980034a4b212",
+ "reference": "224e4a1329c03d8bad520e3fc4ec980034a4b212",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.4",
+ "phpunit/phpunit": "^4.8.36 || ^5.7.21 || ^6.0 || ^7.0 || ^8.0 || ^9.0"
+ },
+ "require-dev": {
+ "yoast/yoastcs": "^2.3.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "2.x-dev"
+ }
+ },
+ "autoload": {
+ "files": [
+ "phpunitpolyfills-autoload.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Team Yoast",
+ "email": "support@yoast.com",
+ "homepage": "https://yoast.com"
+ },
+ {
+ "name": "Contributors",
+ "homepage": "https://github.com/Yoast/PHPUnit-Polyfills/graphs/contributors"
+ }
+ ],
+ "description": "Set of polyfills for changed PHPUnit functionality to allow for creating PHPUnit cross-version compatible tests",
+ "homepage": "https://github.com/Yoast/PHPUnit-Polyfills",
+ "keywords": [
+ "phpunit",
+ "polyfill",
+ "testing"
+ ],
+ "support": {
+ "issues": "https://github.com/Yoast/PHPUnit-Polyfills/issues",
+ "source": "https://github.com/Yoast/PHPUnit-Polyfills"
+ },
+ "time": "2023-08-19T14:25:08+00:00"
}
],
"aliases": [],
@@ -1906,11 +2198,11 @@
"prefer-stable": false,
"prefer-lowest": false,
"platform": {
- "php": ">=5.3.7"
+ "php": ">=5.4.0"
},
"platform-dev": [],
"platform-overrides": {
- "php": "5.3.7"
+ "php": "5.4.0"
},
- "plugin-api-version": "1.1.0"
+ "plugin-api-version": "2.2.0"
}
Index: core/kernel/application.php
===================================================================
--- core/kernel/application.php
+++ core/kernel/application.php
@@ -793,6 +793,13 @@
$this->registerClass('kEmailSendingHelper', KERNEL_PATH . '/utility/email_send.php', 'EmailSender');
$this->registerClass('kSocket', KERNEL_PATH . '/utility/socket.php', 'Socket');
+ // Testing.
+ $this->registerClass('Page', KERNEL_PATH . '/tests/Page/Page.php');
+ $this->registerClass('QAToolsUrlBuilder', KERNEL_PATH . '/tests/Url/QAToolsUrlBuilder.php');
+ $this->registerClass('QAToolsUrlFactory', KERNEL_PATH . '/tests/Url/QAToolsUrlFactory.php');
+ $this->registerClass('AbstractTestCase', KERNEL_PATH . '/../tests/AbstractTestCase.php');
+ $this->registerClass('AbstractBrowserTestCase', KERNEL_PATH . '/../tests/AbstractBrowserTestCase.php');
+
// do not move to config - this helper is used before configs are read
$this->registerClass('kModulesHelper', KERNEL_PATH . self::MODULE_HELPER_PATH, 'ModulesHelper');
$this->registerClass('CKEditor', FULL_PATH . '/core/ckeditor/ckeditor_php5.php');
Index: core/kernel/startup.php
===================================================================
--- core/kernel/startup.php
+++ core/kernel/startup.php
@@ -206,3 +206,5 @@
// system users
define('USER_ROOT', -1);
define('USER_GUEST', -2);
+
+ $GLOBALS['PHPUNIT_MINK_COVERAGE_DATA_DIRECTORY'] = WRITEABLE . '/remote_code_coverage';
Index: core/kernel/tests/Page/Page.php
===================================================================
--- /dev/null
+++ core/kernel/tests/Page/Page.php
@@ -0,0 +1,43 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+use QATools\QATools\HtmlElements\TypifiedPage;
+use QATools\QATools\PageObject\IPageFactory;
+
+/**
+ * The base class to be used for making classes representing pages, that can contain TypifiedElements.
+ */
+class Page extends TypifiedPage
+{
+
+ /**
+ * Reference to kApplication class instance.
+ *
+ * @var kApplication
+ */
+ protected $Application = null;
+
+ /**
+ * Initialize the page.
+ *
+ * @param IPageFactory $page_factory Page factory.
+ */
+ public function __construct(IPageFactory $page_factory)
+ {
+ parent::__construct($page_factory);
+
+ $this->Application =& kApplication::Instance();
+ }
+
+}
Index: core/kernel/tests/Url/QAToolsUrlBuilder.php
===================================================================
--- /dev/null
+++ core/kernel/tests/Url/QAToolsUrlBuilder.php
@@ -0,0 +1,65 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+use QATools\QATools\PageObject\Exception\UrlException;
+use QATools\QATools\PageObject\Url\IBuilder;
+
+final class QAToolsUrlBuilder extends kBase implements IBuilder
+{
+
+ /**
+ * Template.
+ *
+ * @var string
+ */
+ protected $template = '';
+
+ /**
+ * Params.
+ *
+ * @var array
+ */
+ protected $params = array();
+
+ /**
+ * Constructor for the url builder.
+ *
+ * @param array $components The url components.
+ *
+ * @throws UrlException When the path is missing.
+ */
+ public function __construct(array $components)
+ {
+ parent::__construct();
+
+ if ( empty($components['path']) ) {
+ throw new UrlException('No base url specified', UrlException::TYPE_INVALID_URL);
+ }
+
+ $this->template = $components['path'];
+
+ if ( !empty($components['query']) ) {
+ parse_str($components['query'], $this->params);
+ }
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function build(array $params = array())
+ {
+ return $this->Application->HREF($this->template, '', array_merge($this->params, $params));
+ }
+
+}
Index: core/kernel/tests/Url/QAToolsUrlFactory.php
===================================================================
--- /dev/null
+++ core/kernel/tests/Url/QAToolsUrlFactory.php
@@ -0,0 +1,36 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+use QATools\QATools\PageObject\Url\IBuilder;
+use QATools\QATools\PageObject\Url\IUrlFactory;
+
+/**
+ * Responsible for building the URL of pages.
+ */
+class QAToolsUrlFactory implements IUrlFactory
+{
+
+ /**
+ * Returns an instance of a class implementing IBuilder interface based on given arguments.
+ *
+ * @param array $components The url components.
+ *
+ * @return IBuilder
+ */
+ public function getBuilder(array $components)
+ {
+ return new QAToolsUrlBuilder($components);
+ }
+
+}
Index: core/kernel/tests/bootstrap.php
===================================================================
--- /dev/null
+++ core/kernel/tests/bootstrap.php
@@ -0,0 +1,24 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+$start = microtime(true);
+
+define('DBG_ZEND_PRESENT', 1);
+define('INDEX_FILE', 'index.php');
+define('FULL_PATH', realpath(__DIR__ . '/../../..'));
+
+include_once(FULL_PATH . '/core/kernel/startup.php');
+
+$application =& kApplication::Instance();
+$application->Init();
Index: core/tests/AbstractBrowserTestCase.php
===================================================================
--- /dev/null
+++ core/tests/AbstractBrowserTestCase.php
@@ -0,0 +1,119 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+use aik099\PHPUnit\BrowserTestCase;
+use QATools\QATools\HtmlElements\TypifiedPageFactory;
+use QATools\QATools\PageObject\Container;
+
+abstract class AbstractBrowserTestCase extends BrowserTestCase
+{
+
+ /**
+ * Browsers to use for tests.
+ *
+ * @var array
+ */
+ public static $browsers = array(
+ array('alias' => 'default'),
+ );
+
+ /**
+ * Page factory.
+ *
+ * @var TypifiedPageFactory
+ */
+ protected $pageFactory;
+
+ /**
+ * Reference to kApplication class instance.
+ *
+ * @var kApplication
+ */
+ protected $Application = null;
+
+ /**
+ * Connection to database
+ *
+ * @var IDBConnection
+ */
+ protected $Conn;
+
+ /**
+ * Constructs a test case with the given name.
+ *
+ * @param string $name Test case name.
+ * @param array $data Data.
+ * @param string $data_name Data name.
+ *
+ * @access public
+ */
+ public function __construct($name = null, array $data = array(), $data_name = '')
+ {
+ parent::__construct($name, $data, $data_name);
+
+ $this->Application =& kApplication::Instance();
+ $this->Conn =& $this->Application->GetADODBConnection();
+ }
+
+ /**
+ * Creates factory, that can be used for page creation in the tests.
+ *
+ * @return void
+ * @before
+ */
+ protected function setUpTest()
+ {
+ $this->pageFactory = new TypifiedPageFactory($this->getSession(), $this->getPageFactoryConfig());
+ }
+
+ /**
+ * Returns config object to be used during PageFactory initialization.
+ *
+ * @return Container
+ */
+ protected function getPageFactoryConfig()
+ {
+ $container = new Container();
+ $container['url_factory'] = function () {
+ return new QAToolsUrlFactory();
+ };
+
+ return $container;
+ }
+
+ /**
+ * Gets browser configuration aliases.
+ * Allows to decouple actual test server connection details from test cases.
+ *
+ * @return array
+ */
+ public function getBrowserAliases()
+ {
+ static $cache = null;
+
+ if ( !isset($cache) ) {
+ $cache = require_once WRITEABLE . '/mink_config.php';
+
+ // The remote code coverage collection won't work without "baseUrl" in the browser configuration.
+ foreach ( $cache as $alias_name => $browser_configuration ) {
+ if ( !isset($browser_configuration['alias']) && !isset($browser_configuration['baseUrl']) ) {
+ $cache[$alias_name]['baseUrl'] = $this->Application->BaseURL();
+ }
+ }
+ }
+
+ return $cache;
+ }
+
+}
Index: core/tests/AbstractTestCase.php
===================================================================
--- /dev/null
+++ core/tests/AbstractTestCase.php
@@ -0,0 +1,51 @@
+<?php
+/**
+* @version $Id$
+* @package In-Portal
+* @copyright Copyright (C) 1997 - 2023 Intechnic. All rights reserved.
+* @license GNU/GPL
+* In-Portal is Open Source software.
+* This means that this software may have been modified pursuant
+* the GNU General Public License, and as distributed it includes
+* or is derivative of works licensed under the GNU General Public License
+* or other free or open source software licenses.
+* See http://www.in-portal.org/license for copyright notices and details.
+*/
+
+use PHPUnit\Framework\TestCase as BaseTestCase;
+
+abstract class AbstractTestCase extends BaseTestCase
+{
+
+ /**
+ * Reference to kApplication class instance.
+ *
+ * @var kApplication
+ */
+ protected $Application = null;
+
+ /**
+ * Connection to database
+ *
+ * @var IDBConnection
+ */
+ protected $Conn;
+
+ /**
+ * Constructs a test case with the given name.
+ *
+ * @param string $name Test case name.
+ * @param array $data Data.
+ * @param string $data_name Data name.
+ *
+ * @access public
+ */
+ public function __construct($name = null, array $data = array(), $data_name = '')
+ {
+ parent::__construct($name, $data, $data_name);
+
+ $this->Application =& kApplication::Instance();
+ $this->Conn =& $this->Application->GetADODBConnection();
+ }
+
+}
Index: modules/custom/tests/SampleUnitTest.php
===================================================================
--- /dev/null
+++ modules/custom/tests/SampleUnitTest.php
@@ -0,0 +1,32 @@
+<?php
+
+
+class SampleUnitTest extends AbstractTestCase
+{
+
+ /**
+ * @before
+ */
+ public function setUpTest()
+ {
+
+ }
+
+ /**
+ * @after
+ */
+ public function tearDownTest()
+ {
+
+ }
+
+ public function testSample()
+ {
+ $this->assertEquals(
+ '/admin',
+ kUtil::getSystemConfig()->get('AdminDirectory'),
+ 'Default admin directory is wrong'
+ );
+ }
+
+}
Index: modules/custom/tests/SampleWorkflowTest.php
===================================================================
--- /dev/null
+++ modules/custom/tests/SampleWorkflowTest.php
@@ -0,0 +1,40 @@
+<?php
+
+
+use Yoast\PHPUnitPolyfills\Polyfills\AssertStringContains;
+
+class SampleWorkflowTest extends AbstractBrowserTestCase
+{
+
+ use AssertStringContains;
+
+ public function testSampleWithoutPageObjects()
+ {
+ $session = $this->getSession();
+
+ $url = $this->Application->HREF('platform/login/register', '', array('no_amp' => 1));
+ $session->visit($url);
+
+ $page = $session->getPage();
+ $content_box_titles = $page->findAll('css', '.content-box-title');
+
+ if ( !$content_box_titles ) {
+ $this->fail('No content boxes found on the page');
+ }
+
+ $content_box_title = array_shift($content_box_titles);
+
+ $this->assertEquals('User Registration', trim($content_box_title->getText()));
+ }
+
+ public function testSampleWithPageObjects()
+ {
+ $user_registration_page = new UserRegistrationPage($this->pageFactory);
+ $user_registration_page->open();
+
+ $user_registration_page->loginButton->click();
+
+ $this->assertStringContainsString('Incorrect Username or Password', $user_registration_page->getText());
+ }
+
+}
Index: modules/custom/tests/pages/UserRegistrationPage.php
===================================================================
--- /dev/null
+++ modules/custom/tests/pages/UserRegistrationPage.php
@@ -0,0 +1,19 @@
+<?php
+
+use QATools\QATools\HtmlElements\Element\Button;
+
+/**
+ * @page-url('platform/login/register', 'params' => array('p1' => 'v1'))
+ */
+final class UserRegistrationPage extends Page
+{
+
+ /**
+ * Registration button.
+ *
+ * @var Button
+ * @find-by('name' => 'events[u.login-sidebox][OnLogin]')
+ */
+ public $loginButton;
+
+}
Index: modules/custom/tests/tests_config.php
===================================================================
--- /dev/null
+++ modules/custom/tests/tests_config.php
@@ -0,0 +1,12 @@
+<?php
+defined('FULL_PATH') or die('restricted access!');
+
+$config = array(
+ 'Prefix' => 'custom-tests',
+
+ 'EventHandlerClass' => array('class' => 'kEventHandler', 'file' => '', 'build_event' => 'OnBuild'),
+
+ 'RegisterClasses' => array(
+ array('pseudo' => 'UserRegistrationPage', 'class' => 'UserRegistrationPage', 'file' => 'pages/UserRegistrationPage.php'),
+ ),
+);
Index: tools/build/inc/custom_phpunit.xml
===================================================================
--- tools/build/inc/custom_phpunit.xml
+++ tools/build/inc/custom_phpunit.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit colors="true"
bootstrap="../../../core/kernel/tests/bootstrap.php"
- strict="true"
+ beStrictAboutOutputDuringTests="true"
verbose="true">
<php>
@@ -16,22 +16,19 @@
</testsuite>
</testsuites>
- <listeners>
- <listener class="\Mockery\Adapter\Phpunit\TestListener"/>
- </listeners>
-
<logging>
<!--<log type="coverage-html" target="../../../build/coverage" title="BankAccount"
charset="UTF-8" yui="true" highlight="true"
lowUpperBound="35" highLowerBound="70"/>
<log type="coverage-clover" target="../../../build/logs/clover.xml"/>-->
- <log type="junit" target="../../../build/logs/junit.xml" logIncompleteSkipped="false"/>
+ <log type="junit" target="../../../build/logs/junit.xml"/>
+ <!--<log type="junit" target="../../../build/logs/junit.xml" logIncompleteSkipped="false"/>-->
</logging>
<filter>
- <blacklist>
+ <!--<blacklist>
<directory suffix=".php">..</directory>
- </blacklist>
+ </blacklist>-->
<whitelist addUncoveredFilesFromWhitelist="true">
<directory suffix=".php">../../../modules/custom</directory>
<exclude>
Index: tools/build/inc/phpunit.xml
===================================================================
--- tools/build/inc/phpunit.xml
+++ tools/build/inc/phpunit.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit colors="true"
bootstrap="../../../core/kernel/tests/bootstrap.php"
- strict="true"
+ beStrictAboutOutputDuringTests="true"
verbose="true">
<php>
@@ -19,22 +19,19 @@
</testsuite>
</testsuites>
- <listeners>
- <listener class="\Mockery\Adapter\Phpunit\TestListener"/>
- </listeners>
-
<logging>
<!--<log type="coverage-html" target="../../../build/coverage" title="BankAccount"
charset="UTF-8" yui="true" highlight="true"
lowUpperBound="35" highLowerBound="70"/>
<log type="coverage-clover" target="../../../build/logs/clover.xml"/>-->
- <log type="junit" target="../../../build/logs/junit.xml" logIncompleteSkipped="false"/>
+ <log type="junit" target="../../../build/logs/junit.xml"/>
+ <!--<log type="junit" target="../../../build/logs/junit.xml" logIncompleteSkipped="false"/>-->
</logging>
<filter>
- <blacklist>
+ <!--<blacklist>
<directory suffix=".php">..</directory>
- </blacklist>
+ </blacklist>-->
<whitelist addUncoveredFilesFromWhitelist="true">
<directory suffix=".php">../../..</directory>
<exclude>
Index: tools/mink_config.php-dist
===================================================================
--- /dev/null
+++ tools/mink_config.php-dist
@@ -0,0 +1,12 @@
+<?php
+return array(
+ 'default' => array('alias' => 'ff_local'),
+
+ 'ff_local' => array(
+ 'browserName' => 'firefox', 'host' => 'localhost', 'port' => 4444, 'timeout' => 15
+ ),
+
+ 'cr_local' => array(
+ 'browserName' => 'chrome', 'host' => 'localhost', 'port' => 4444,
+ ),
+);
Event Timeline
Log In to Comment