aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2017-05-03 10:23:49 +0200
committerJeremy Benoist <jeremy.benoist@gmail.com>2017-06-20 16:03:20 +0200
commit9de9f1e5ceed4ac7ecd27e1cb808e630a831f94b (patch)
tree6db9842b413ba4cec80b1d36c54cf77bf1a4c2c0 /tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php
parentfd7fde95159828960784a438c4b4da147e20ab18 (diff)
downloadwallabag-9de9f1e5ceed4ac7ecd27e1cb808e630a831f94b.tar.gz
wallabag-9de9f1e5ceed4ac7ecd27e1cb808e630a831f94b.tar.zst
wallabag-9de9f1e5ceed4ac7ecd27e1cb808e630a831f94b.zip
Add a live test for restricted article
It is not aimed to test if we can get the full article (since we aren't using real login/password) but mostly to test the full work (with authentication, etc.) Do not clean fixtured to avoid SQLite to re-use id for entry tag relation 😓
Diffstat (limited to 'tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php')
-rw-r--r--tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php b/tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php
index 980f7579..1e1e8989 100644
--- a/tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php
+++ b/tests/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilderTest.php
@@ -25,7 +25,7 @@ class GrabySiteConfigBuilderTest extends PHPUnit_Framework_TestCase
25 25
26 $grabySiteConfig = new GrabySiteConfig(); 26 $grabySiteConfig = new GrabySiteConfig();
27 $grabySiteConfig->requires_login = true; 27 $grabySiteConfig->requires_login = true;
28 $grabySiteConfig->login_uri = 'http://example.com/login'; 28 $grabySiteConfig->login_uri = 'http://www.example.com/login';
29 $grabySiteConfig->login_username_field = 'login'; 29 $grabySiteConfig->login_username_field = 'login';
30 $grabySiteConfig->login_password_field = 'password'; 30 $grabySiteConfig->login_password_field = 'password';
31 $grabySiteConfig->login_extra_fields = ['field=value']; 31 $grabySiteConfig->login_extra_fields = ['field=value'];
@@ -67,13 +67,13 @@ class GrabySiteConfigBuilderTest extends PHPUnit_Framework_TestCase
67 $logger 67 $logger
68 ); 68 );
69 69
70 $config = $this->builder->buildForHost('example.com'); 70 $config = $this->builder->buildForHost('www.example.com');
71 71
72 $this->assertEquals( 72 $this->assertEquals(
73 new SiteConfig([ 73 new SiteConfig([
74 'host' => 'example.com', 74 'host' => 'example.com',
75 'requiresLogin' => true, 75 'requiresLogin' => true,
76 'loginUri' => 'http://example.com/login', 76 'loginUri' => 'http://www.example.com/login',
77 'usernameField' => 'login', 77 'usernameField' => 'login',
78 'passwordField' => 'password', 78 'passwordField' => 'password',
79 'extraFields' => ['field' => 'value'], 79 'extraFields' => ['field' => 'value'],