File tree Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace Embed \Providers \OEmbed ;
4
+
5
+ class Reddit extends EndPoint implements EndPointInterface
6
+ {
7
+ protected static $ pattern = 'www.reddit.com/* ' ;
8
+ protected static $ endPoint = 'https://www.reddit.com/oembed ' ;
9
+ }
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace Embed \Tests ;
4
+
5
+ class RedditTest extends AbstractTestCase
6
+ {
7
+ public function testOne ()
8
+ {
9
+ $ this ->assertEmbed (
10
+ 'https://www.reddit.com/r/investing/comments/7pfpeq/buffett_on_cyrptocurrencies_i_can_say_almost_with/ ' ,
11
+ [
12
+ 'title ' => "Buffett on cyrptocurrencies: 'I can say almost with certainty that they will come to a bad ending' " ,
13
+ 'type ' => 'rich ' ,
14
+ 'authorName ' => 'dennisrieves ' ,
15
+ 'providerName ' => 'reddit ' ,
16
+ ]
17
+ );
18
+ }
19
+ }
You can’t perform that action at this time.
0 commit comments