Skip to content

Commit a1b59fd

Browse files
authored
Merge pull request #94 from iMattPro/updates
Just some updates
2 parents dc6579f + ded1621 commit a1b59fd

6 files changed

Lines changed: 31 additions & 37 deletions

File tree

.github/workflows/tests.yml

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ on:
2121
jobs:
2222
# START Basic Checks Job (EPV, code sniffer, images check, etc.)
2323
basic-checks:
24-
runs-on: ubuntu-18.04
24+
runs-on: ubuntu-20.04
2525
strategy:
2626
matrix:
2727
include:
@@ -33,14 +33,14 @@ jobs:
3333

3434
steps:
3535
- name: Checkout phpBB
36-
uses: actions/checkout@v2
36+
uses: actions/checkout@v3
3737
with:
3838
repository: phpbb/phpbb
3939
ref: ${{ env.PHPBB_BRANCH }}
4040
path: phpBB3
4141

4242
- name: Checkout extension
43-
uses: actions/checkout@v2
43+
uses: actions/checkout@v3
4444
with:
4545
path: phpBB3/phpBB/ext/${{ env.EXTNAME }}
4646

@@ -89,7 +89,7 @@ jobs:
8989

9090
# START MySQL and MariaDB Job
9191
mysql-tests:
92-
runs-on: ubuntu-18.04
92+
runs-on: ubuntu-20.04
9393
strategy:
9494
matrix:
9595
include:
@@ -156,14 +156,14 @@ jobs:
156156

157157
steps:
158158
- name: Checkout phpBB
159-
uses: actions/checkout@v2
159+
uses: actions/checkout@v3
160160
with:
161161
repository: phpbb/phpbb
162162
ref: ${{ env.PHPBB_BRANCH }}
163163
path: phpBB3
164164

165165
- name: Checkout extension
166-
uses: actions/checkout@v2
166+
uses: actions/checkout@v3
167167
with:
168168
path: phpBB3/phpBB/ext/${{ env.EXTNAME }}
169169

@@ -172,7 +172,7 @@ jobs:
172172
MATRIX_DB: ${{ matrix.db }}
173173
run: |
174174
db=$(echo "${MATRIX_DB%%:*}")
175-
echo "::set-output name=db::$db"
175+
echo "db=$db" >> $GITHUB_OUTPUT
176176
177177
- name: Setup PHP
178178
if: ${{ matrix.COVERAGE != 1 }}
@@ -240,7 +240,7 @@ jobs:
240240

241241
# START PostgreSQL Job
242242
postgres-tests:
243-
runs-on: ubuntu-18.04
243+
runs-on: ubuntu-20.04
244244
strategy:
245245
matrix:
246246
include:
@@ -301,14 +301,14 @@ jobs:
301301

302302
steps:
303303
- name: Checkout phpBB
304-
uses: actions/checkout@v2
304+
uses: actions/checkout@v3
305305
with:
306306
repository: phpbb/phpbb
307307
ref: ${{ env.PHPBB_BRANCH }}
308308
path: phpBB3
309309

310310
- name: Checkout extension
311-
uses: actions/checkout@v2
311+
uses: actions/checkout@v3
312312
with:
313313
path: phpBB3/phpBB/ext/${{ env.EXTNAME }}
314314

@@ -317,7 +317,7 @@ jobs:
317317
MATRIX_DB: ${{ matrix.db }}
318318
run: |
319319
db=$(echo "${MATRIX_DB%%:*}")
320-
echo "::set-output name=db::$db"
320+
echo "db=$db" >> $GITHUB_OUTPUT
321321
322322
- name: Setup PHP
323323
uses: shivammathur/setup-php@v2
@@ -354,7 +354,7 @@ jobs:
354354

355355
# START Other Tests Job (SQLite 3 and mssql)
356356
other-tests:
357-
runs-on: ubuntu-18.04
357+
runs-on: ubuntu-20.04
358358
strategy:
359359
matrix:
360360
include:
@@ -396,14 +396,14 @@ jobs:
396396

397397
steps:
398398
- name: Checkout phpBB
399-
uses: actions/checkout@v2
399+
uses: actions/checkout@v3
400400
with:
401401
repository: phpbb/phpbb
402402
ref: ${{ env.PHPBB_BRANCH }}
403403
path: phpBB3
404404

405405
- name: Checkout extension
406-
uses: actions/checkout@v2
406+
uses: actions/checkout@v3
407407
with:
408408
path: phpBB3/phpBB/ext/${{ env.EXTNAME }}
409409

@@ -417,7 +417,7 @@ jobs:
417417
else
418418
db=$(echo "${MATRIX_DB%%:*}")
419419
fi
420-
echo "::set-output name=db::$db"
420+
echo "db=$db" >> $GITHUB_OUTPUT
421421
422422
- name: Setup PHP
423423
uses: shivammathur/setup-php@v2

collection/sites/clyp.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

collection/sites/codepen.yml

Lines changed: 0 additions & 8 deletions
This file was deleted.

event/main_listener.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ public function disable_media_embed($event)
229229
}
230230

231231
/**
232-
* setup a cache directory to improve scraping performance
232+
* Set up a cache directory to improve scraping performance
233233
*
234234
* @param \phpbb\event\data $event The event object
235235
* @return void
@@ -315,7 +315,7 @@ public function check_bbcode_enabled($event)
315315
{
316316
if (!$event['allow_bbcode'])
317317
{
318-
// Want to leave plugin enabled but it seems plugin won't work
318+
// Want to leave plugin enabled, but it seems plugin won't work
319319
// when tag is disabled, so we have to disable both it seems.
320320
$this->disable_plugin = true;
321321
$this->disable_tag = true;

ext.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,16 @@
1212

1313
class ext extends \phpbb\extension\base
1414
{
15-
/** @var string Minimum requirements: phpBB 3.3.2 because using role_exists in migrations */
15+
/**
16+
* @var string Minimum requirements:
17+
* phpBB 3.3.2 because using role_exists in migrations
18+
* ph[BB 3.3.2 because TextFormatter 2.7.5 supports clyp.it and codepen.com
19+
*/
1620
public const PHPBB_MINIMUM = '3.3.2';
1721

18-
/** @var string YAML file extension */
22+
/**
23+
* @var string YAML file extension
24+
*/
1925
public const YML = '.yml';
2026

2127
/**

tests/custom_sites_collection_test.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,13 @@ public function test_get_collection()
4646

4747
$collection = $customsitescollection->get_collection();
4848

49-
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/codepen.yml', $collection);
50-
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/snotr.yml', $collection);
49+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/allocine.yml', $collection);
50+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/dotsub.yml', $collection);
51+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/ebaumsworld.yml', $collection);
52+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/moddb.yml', $collection);
5153
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/ok.yml', $collection);
54+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/schooltube.yml', $collection);
55+
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/snotr.yml', $collection);
5256
$this->assertContains('phpBB/ext/phpbb/mediaembed/collection/sites/videopress.yml', $collection);
5357
$this->assertNotContains('phpBB/ext/phpbb/mediaembed/collection/sites/youtube.yml', $collection);
5458
}

0 commit comments

Comments
 (0)