Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
minor #17911 [Ldap] Added environment-based Ldap server configuration…
… for tests (csarrazi) This PR was merged into the 3.1-dev branch. Discussion ---------- [Ldap] Added environment-based Ldap server configuration for tests | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | This PR makes Ldap server host and port configurable by using environment variables. This enables a developer to test the Ldap component locally, or on a vagrant virtual machine, depending on the use case. If one wishes to run the tests against his own Ldap server, one simply needs to use the `LDAP_HOST` and `LDAP_PORT` environment variables when running the `phpunit` command. Commits ------- d0fbaea Added environment-based Ldap server configuration for tests
- Loading branch information
Showing
5 changed files
with
22 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
namespace Symfony\Component\Ldap\Tests; | ||
|
||
class LdapTestCase extends \PHPUnit_Framework_TestCase | ||
{ | ||
protected function getLdapConfig() | ||
{ | ||
return array( | ||
'host' => getenv('LDAP_HOST'), | ||
'port' => getenv('LDAP_PORT'), | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters