Autoload.php
9 years ago
TestEmbera.php
9 years ago
TestFakeResponse.php
9 years ago
TestFormatter.php
9 years ago
TestHttpRequest.php
9 years ago
TestOembed.php
9 years ago
TestProviders.php
9 years ago
TestServiceAmCharts.php
9 years ago
TestServiceAnimatron.php
9 years ago
TestServiceAnimoto.php
9 years ago
TestServiceAolOn.php
9 years ago
TestServiceAppNet.php
9 years ago
TestServiceAudioSnaps.php
9 years ago
TestServiceBambuser.php
9 years ago
TestServiceBlipTv.php
9 years ago
TestServiceCacoo.php
9 years ago
TestServiceChartblocks.php
9 years ago
TestServiceChirbit.php
9 years ago
TestServiceCircuitLab.php
9 years ago
TestServiceClyp.php
9 years ago
TestServiceCodepoints.php
9 years ago
TestServiceCollegeHumor.php
9 years ago
TestServiceCoub.php
9 years ago
TestServiceCrowdRanking.php
9 years ago
TestServiceDailyMile.php
9 years ago
TestServiceDailyMotion.php
9 years ago
TestServiceDeviantart.php
9 years ago
TestServiceDipity.php
9 years ago
TestServiceDotSub.php
9 years ago
TestServiceEdocr.php
9 years ago
TestServiceEgliseInfo.php
9 years ago
TestServiceFacebook.php
9 years ago
TestServiceFlickr.php
9 years ago
TestServiceFunnyOrDie.php
9 years ago
TestServiceGeographCI.php
9 years ago
TestServiceGeographDe.php
9 years ago
TestServiceGeographUk.php
9 years ago
TestServiceGettyImages.php
9 years ago
TestServiceGfycat.php
9 years ago
TestServiceGithubGist.php
9 years ago
TestServiceGmep.php
9 years ago
TestServiceHq23.php
9 years ago
TestServiceHuffduffer.php
9 years ago
TestServiceHulu.php
9 years ago
TestServiceIFTTT.php
9 years ago
TestServiceIFixIt.php
9 years ago
TestServiceInfogram.php
9 years ago
TestServiceInstagram.php
9 years ago
TestServiceIssuu.php
9 years ago
TestServiceIssuuFakeResponse.php
9 years ago
TestServiceKickstarter.php
9 years ago
TestServiceLearningApps.php
9 years ago
TestServiceMeetup.php
9 years ago
TestServiceMixCloud.php
9 years ago
TestServiceMobyPicture.php
9 years ago
TestServiceNFB.php
9 years ago
TestServiceOfficeMix.php
9 years ago
TestServiceOfficialFM.php
9 years ago
TestServiceOumy.php
9 years ago
TestServicePastery.php
9 years ago
TestServicePollDaddy.php
9 years ago
TestServicePollEverywhere.php
9 years ago
TestServicePortfolium.php
9 years ago
TestServiceRapidengage.php
9 years ago
TestServiceRdio.php
9 years ago
TestServiceReleaseWire.php
9 years ago
TestServiceRepubHub.php
9 years ago
TestServiceReverbnation.php
9 years ago
TestServiceRevision3.php
9 years ago
TestServiceRoomshare.php
9 years ago
TestServiceRutube.php
9 years ago
TestServiceSapo.php
9 years ago
TestServiceScreenr.php
9 years ago
TestServiceScribd.php
9 years ago
TestServiceShortNote.php
9 years ago
TestServiceShoudio.php
9 years ago
TestServiceShowTheWay.php
9 years ago
TestServiceSilk.php
9 years ago
TestServiceSketchfab.php
9 years ago
TestServiceSlideshare.php
9 years ago
TestServiceSoundCloud.php
9 years ago
TestServiceSpeakerDeck.php
9 years ago
TestServiceSpotify.php
9 years ago
TestServiceSway.php
9 years ago
TestServiceTed.php
9 years ago
TestServiceTheySaidSo.php
9 years ago
TestServiceTwitter.php
9 years ago
TestServiceUstream.php
9 years ago
TestServiceVerse.php
9 years ago
TestServiceViddler.php
9 years ago
TestServiceVideoFork.php
9 years ago
TestServiceVideoJug.php
9 years ago
TestServiceVimeo.php
9 years ago
TestServiceVine.php
9 years ago
TestServiceWordpressTV.php
9 years ago
TestServiceYFrog.php
9 years ago
TestServiceYandex.php
9 years ago
TestServiceYoutube.php
9 years ago
TestUrl.php
9 years ago
Autoload.php
50 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Setup the environment |
| 4 | */ |
| 5 | date_default_timezone_set('UTC'); |
| 6 | if (file_exists(__DIR__ . '/../vendor/autoload.php')) |
| 7 | require __DIR__ . '/../vendor/autoload.php'; |
| 8 | else |
| 9 | require __DIR__ . '/../Lib/Embera/Autoload.php'; |
| 10 | |
| 11 | /** |
| 12 | * HttpRequest Mockup |
| 13 | * @codeCoverageIgnore |
| 14 | */ |
| 15 | class MockHttpRequest extends \Embera\HttpRequest |
| 16 | { |
| 17 | public $response; |
| 18 | public function fetch($url, array $params = array()) |
| 19 | { |
| 20 | $url = true; |
| 21 | return $this->response; |
| 22 | } |
| 23 | } |
| 24 | |
| 25 | /** |
| 26 | * A custom Service |
| 27 | */ |
| 28 | class CustomService extends \Embera\Adapters\Service |
| 29 | { |
| 30 | protected $apiUrl = 'http://my-custom-service.com/oembed.json'; |
| 31 | public function validateUrl() |
| 32 | { |
| 33 | return preg_match('~customservice\.com/([0-9]+)~i', $this->url); |
| 34 | } |
| 35 | } |
| 36 | |
| 37 | /** |
| 38 | * Oembed Mockup |
| 39 | * @codeCoverageIgnore |
| 40 | */ |
| 41 | class MockOembed extends \Embera\Oembed |
| 42 | { |
| 43 | public function getResourceInfo($behaviour, $apiUrl, $url, array $params = array()) |
| 44 | { |
| 45 | $behaviour = $apiUrl = $url = $params = true; |
| 46 | return array(); |
| 47 | } |
| 48 | } |
| 49 | ?> |
| 50 |