Skip to content

Commit d022ce5

Browse files
Working on next version
1 parent 3969aef commit d022ce5

16 files changed

+108
-108
lines changed

.github/workflows/tests.yml

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,17 @@ jobs:
1111

1212
strategy:
1313
matrix:
14-
php: ['7.4', '8.0', '8.1']
15-
laravel: ['8', '9']
14+
php: ['7.4', '8.0', '8.1', '8.2']
15+
laravel: ['8', '9', '10']
1616
exclude:
1717
- php: '7.4'
1818
laravel: '9'
19+
- php: '7.4'
20+
laravel: '10'
21+
- php: '8.0'
22+
laravel: '10'
23+
- php: '8.2'
24+
laravel: '8'
1925

2026
steps:
2127
- name: Checkout Code
@@ -27,6 +33,8 @@ jobs:
2733
php-version: ${{ matrix.php }}
2834
tools: composer:v2
2935
coverage: none
36+
env:
37+
update: true
3038

3139
- name: Setup Problem Matchers
3240
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
@@ -36,17 +44,25 @@ jobs:
3644
with:
3745
timeout_minutes: 5
3846
max_attempts: 5
39-
command: composer require "laravel/framework:^8.75" --no-update --no-interaction
47+
command: composer require "laravel/framework:^8.83.27" "phpunit/phpunit:^9.6.3" --no-update --no-interaction
4048
if: "matrix.laravel == '8'"
4149

4250
- name: Select Laravel 9
4351
uses: nick-invision/retry@v2
4452
with:
4553
timeout_minutes: 5
4654
max_attempts: 5
47-
command: composer require "laravel/framework:^9.0" --no-update --no-interaction
55+
command: composer require "laravel/framework:^9.52.4" "phpunit/phpunit:^9.6.3" --no-update --no-interaction
4856
if: "matrix.laravel == '9'"
4957

58+
- name: Select Laravel 10
59+
uses: nick-invision/retry@v2
60+
with:
61+
timeout_minutes: 5
62+
max_attempts: 5
63+
command: composer require "laravel/framework:^10.1.5" "phpunit/phpunit:^10.0.12" --no-update --no-interaction
64+
if: "matrix.laravel == '10'"
65+
5066
- name: Install PHP Dependencies
5167
uses: nick-invision/retry@v2
5268
with:

README.md

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Laravel Markdown was created by, and is maintained by [Graham Campbell](https://
66
![Banner](https://user-images.githubusercontent.com/2829600/71477505-680d0f80-27e2-11ea-94a6-b4bacb08e270.png)
77

88
<p align="center">
9-
<a href="https://github.com/GrahamCampbell/Laravel-Markdown/actions?query=workflow%3ATests"><img src="https://img.shields.io/github/workflow/status/GrahamCampbell/Laravel-Markdown/Tests?label=Tests&style=flat-square" alt="Build Status"></img></a>
9+
<a href="https://github.com/GrahamCampbell/Laravel-Markdown/actions?query=workflow%3ATests"><img src="https://img.shields.io/github/actions/workflow/status/GrahamCampbell/Laravel-Markdown/tests.yml?label=Tests&style=flat-square" alt="Build Status"></img></a>
1010
<a href="https://github.styleci.io/repos/15090687"><img src="https://github.styleci.io/repos/15090687/shield" alt="StyleCI Status"></img></a>
1111
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-brightgreen?style=flat-square" alt="Software License"></img></a>
1212
<a href="https://packagist.org/packages/graham-campbell/markdown"><img src="https://img.shields.io/packagist/dt/graham-campbell/markdown?style=flat-square" alt="Packagist Downloads"></img></a>
@@ -16,25 +16,21 @@ Laravel Markdown was created by, and is maintained by [Graham Campbell](https://
1616

1717
## Installation
1818

19-
This version requires [PHP](https://www.php.net/) 7.4-8.1 and supports [Laravel](https://laravel.com/) 8-9.
20-
21-
| Markdown | L5.1 | L5.2 | L5.3 | L5.4 | L5.5 | L5.6 | L5.7 | L5.8 | L6 | L7 | L8 | L9 |
22-
|----------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|
23-
| 5.3 | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
24-
| 6.1 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
25-
| 7.1 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
26-
| 8.1 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
27-
| 9.0 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: | :x: | :x: |
28-
| 10.3 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: |
29-
| 11.2 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: |
30-
| 12.0 | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :x: | :x: |
31-
| 13.1 | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: |
32-
| 14.0 | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: |
19+
This version requires [PHP](https://www.php.net/) 7.4-8.2 and supports [Laravel](https://laravel.com/) 8-10.
20+
21+
| Markdown | L5.5 | L5.6 | L5.7 | L5.8 | L6 | L7 | L8 | L9 | L10 |
22+
|----------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|
23+
| 10.3 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: | :x: | :x: |
24+
| 11.2 | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: |
25+
| 12.0 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :x: | :x: | :x: |
26+
| 13.1 | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :x: |
27+
| 14.0 | :x: | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :x: |
28+
| 15.0 | :x: | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: |
3329

3430
To get the latest version, simply require the project using [Composer](https://getcomposer.org/):
3531

3632
```bash
37-
$ composer require graham-campbell/markdown:^14.0
33+
$ composer require "graham-campbell/markdown:^15.0"
3834
```
3935

4036
Once installed, if you are not using automatic package discovery, then you need to register the `GrahamCampbell\Markdown\MarkdownServiceProvider` service provider in your `config/app.php`.

composer.json

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,17 @@
1212
],
1313
"require": {
1414
"php": "^7.4.15 || ^8.0.2",
15-
"illuminate/contracts": "^8.75 || ^9.0",
16-
"illuminate/filesystem": "^8.75 || ^9.0",
17-
"illuminate/support": "^8.75 || ^9.0",
18-
"illuminate/view": "^8.75 || ^9.0",
19-
"league/commonmark": "^2.3.1"
15+
"illuminate/contracts": "^8.75 || ^9.0 || ^10.0",
16+
"illuminate/filesystem": "^8.75 || ^9.0 || ^10.0",
17+
"illuminate/support": "^8.75 || ^9.0 || ^10.0",
18+
"illuminate/view": "^8.75 || ^9.0 || ^10.0",
19+
"league/commonmark": "^2.3.9"
2020
},
2121
"require-dev": {
22-
"graham-campbell/analyzer": "^3.1",
23-
"graham-campbell/testbench": "^5.7",
24-
"mockery/mockery": "^1.5",
25-
"phpunit/phpunit": "^9.5"
22+
"graham-campbell/analyzer": "^4.0",
23+
"graham-campbell/testbench": "^6.0",
24+
"mockery/mockery": "^1.5.1",
25+
"phpunit/phpunit": "^9.6.3 || ^10.0.12"
2626
},
2727
"autoload": {
2828
"psr-4": {
@@ -43,7 +43,5 @@
4343
"GrahamCampbell\\Markdown\\MarkdownServiceProvider"
4444
]
4545
}
46-
},
47-
"minimum-stability": "dev",
48-
"prefer-stable": true
46+
}
4947
}

phpunit.xml.dist

Lines changed: 11 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,13 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit backupGlobals="false"
3-
backupStaticAttributes="false"
4-
beStrictAboutTestsThatDoNotTestAnything="true"
5-
beStrictAboutOutputDuringTests="true"
6-
bootstrap="vendor/autoload.php"
7-
colors="true"
8-
convertDeprecationsToExceptions="true"
9-
convertErrorsToExceptions="true"
10-
convertNoticesToExceptions="true"
11-
convertWarningsToExceptions="true"
12-
failOnRisky="true"
13-
failOnWarning="true"
14-
processIsolation="false"
15-
stopOnError="false"
16-
stopOnFailure="false"
17-
verbose="true"
18-
>
19-
<testsuites>
20-
<testsuite name="Laravel Markdown Test Suite">
21-
<directory suffix="Test.php">./tests</directory>
22-
</testsuite>
23-
</testsuites>
24-
<coverage processUncoveredFiles="true">
25-
<include>
26-
<directory suffix=".php">./src</directory>
27-
</include>
28-
</coverage>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" beStrictAboutTestsThatDoNotTestAnything="true" beStrictAboutOutputDuringTests="true" bootstrap="vendor/autoload.php" colors="true" failOnRisky="true" failOnWarning="true" processIsolation="false" stopOnError="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.0/phpunit.xsd">
3+
<testsuites>
4+
<testsuite name="Laravel Markdown Test Suite">
5+
<directory suffix="Test.php">./tests</directory>
6+
</testsuite>
7+
</testsuites>
8+
<coverage>
9+
<include>
10+
<directory suffix=".php">./src</directory>
11+
</include>
12+
</coverage>
2913
</phpunit>

src/Facades/Markdown.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class Markdown extends Facade
2525
*
2626
* @return string
2727
*/
28-
protected static function getFacadeAccessor()
28+
protected static function getFacadeAccessor(): string
2929
{
3030
return 'markdown.converter';
3131
}

src/MarkdownServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ protected function registerDirective(): void
240240
*
241241
* @return string[]
242242
*/
243-
public function provides()
243+
public function provides(): array
244244
{
245245
return [
246246
'markdown.environment',

src/View/Engine/BladeCommonMarkEngine.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public function __construct(CompilerInterface $compiler, Filesystem $files, Conv
4747
*
4848
* @return string
4949
*/
50-
public function get($path, array $data = [])
50+
public function get($path, array $data = []): string
5151
{
5252
$contents = parent::get($path, $data);
5353

src/View/Engine/PhpCommonMarkEngine.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public function __construct(Filesystem $files, ConverterInterface $converter)
4545
*
4646
* @return string
4747
*/
48-
public function get($path, array $data = [])
48+
public function get($path, array $data = []): string
4949
{
5050
$contents = parent::get($path, $data);
5151

tests/AbstractTestCase.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ abstract class AbstractTestCase extends AbstractPackageTestCase
2626
*
2727
* @return string
2828
*/
29-
protected function getServiceProviderClass()
29+
protected static function getServiceProviderClass(): string
3030
{
3131
return MarkdownServiceProvider::class;
3232
}

tests/AnalysisTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ class AnalysisTest extends TestCase
2929
*
3030
* @return string[]
3131
*/
32-
protected function getPaths()
32+
protected static function getPaths(): array
3333
{
3434
return [
3535
realpath(__DIR__.'/../config'),
@@ -43,7 +43,7 @@ protected function getPaths()
4343
*
4444
* @return string[]
4545
*/
46-
protected function getIgnored()
46+
protected static function getIgnored(): array
4747
{
4848
return [Application::class];
4949
}

0 commit comments

Comments
 (0)