Skip to content

Commit aca5a71

Browse files
committed
Fix unit tests
1 parent 3b060af commit aca5a71

File tree

2 files changed

+2
-18
lines changed

2 files changed

+2
-18
lines changed

src/codebird.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,7 @@ class Codebird
7777
'oauth' => 'https://api.twitter.com/',
7878
'rest' => 'https://api.twitter.com/1.1/',
7979
'streaming' => [
80-
'public' => 'https://stream.twitter.com/1.1/',
81-
'user' => 'https://userstream.twitter.com/1.1/',
82-
'site' => 'https://sitestream.twitter.com/1.1/'
80+
'public' => 'https://stream.twitter.com/1.1/'
8381
],
8482
'ton' => 'https://ton.twitter.com/1.1/'
8583
];
@@ -2016,7 +2014,7 @@ protected function _detectStreaming($method) {
20162014
$streamings = [
20172015
'public' => [
20182016
'statuses/sample',
2019-
'statuses/filter',
2017+
'statuses/filter'
20202018
]
20212019
];
20222020
foreach ($streamings as $key => $values) {

test/detection_tests.php

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,6 @@ public function testDetectMultipart()
172172
{
173173
$cb = $this->getCB();
174174
$this->assertFalse($cb->call('_detectMultipart', ['statuses/update']));
175-
$this->assertTrue($cb->call('_detectMultipart', ['statuses/update_with_media']));
176175
$this->assertTrue($cb->call('_detectMultipart', ['media/upload']));
177176
}
178177

@@ -221,9 +220,6 @@ public function testDetectStreaming()
221220
$this->assertFalse($cb->call('_detectStreaming', ['statuses/update']));
222221
$this->assertEquals('public', $cb->call('_detectStreaming', ['statuses/sample']));
223222
$this->assertEquals('public', $cb->call('_detectStreaming', ['statuses/filter']));
224-
$this->assertEquals('public', $cb->call('_detectStreaming', ['statuses/firehose']));
225-
$this->assertEquals('user', $cb->call('_detectStreaming', ['user']));
226-
$this->assertEquals('site', $cb->call('_detectStreaming', ['site']));
227223
}
228224

229225
/**
@@ -267,16 +263,6 @@ public function testGetEndpoint()
267263
$cb->call('_getEndpoint', ['statuses/filter', 'statuses/filter']),
268264
'statuses/filter'
269265
);
270-
$this->assertEquals(
271-
'https://sitestream.twitter.com/1.1/site.json',
272-
$cb->call('_getEndpoint', ['site', 'site']),
273-
'site'
274-
);
275-
$this->assertEquals(
276-
'https://userstream.twitter.com/1.1/user.json',
277-
$cb->call('_getEndpoint', ['user', 'user']),
278-
'user'
279-
);
280266
$this->assertEquals(
281267
'https://ton.twitter.com/1.1/ton/bucket/ta_partner',
282268
$cb->call('_getEndpoint', ['ton/bucket/ta_partner', 'ton/bucket/:bucket']),

0 commit comments

Comments
 (0)