Skip to content

Commit 0c49340

Browse files
committed
Merge branch 'release/0.6.7'
2 parents 5e6d027 + 1fb411f commit 0c49340

File tree

7 files changed

+43
-21
lines changed

7 files changed

+43
-21
lines changed

.github/workflows/ci.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: CI
2+
3+
on: [push]
4+
5+
jobs:
6+
build-test:
7+
runs-on: ubuntu-latest
8+
container:
9+
image: php:8.4 # This forces the job to run in a Docker container
10+
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v3
14+
15+
- name: Install System Dependencies (Git, Zip, Unzip)
16+
run: |
17+
apt-get update
18+
apt-get install -y unzip git zip
19+
20+
- name: Install and Enable extensions
21+
run: |
22+
docker-php-ext-install sockets calendar
23+
docker-php-ext-enable sockets calendar
24+
25+
- name: Install Composer
26+
run: |
27+
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
28+
composer --version
29+
30+
- name: Install Dependencies
31+
run: composer install --prefer-dist --no-progress
32+
33+
- name: Run PHPUnit
34+
run: vendor/bin/phpunit tests

VERSIONLOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1+
## 0.6.7 2025-02-06
12
## 0.6.6 2025-01-27
2-
* Update data to 0.7
33

44
## 0.6.5
55
## 0.6.4
66
## 0.6.3 2024-11-27
77
* Updated route signatures.
8-
* Added logging.
8+
* Added logging
99

1010
## 0.6.2 2024-11-27
1111
* Updated dependencies.

src/Routing/RouteMap.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Neuron\Routing;
44

55
use Exception;
6+
use Neuron\Core\Exceptions\RouteParam;
67

78
class RouteMap
89
{
@@ -166,7 +167,7 @@ public function parseParams(): array
166167
/**
167168
* @param $Param
168169
* @param $Params
169-
* @throws RouteParamException
170+
* @throws RouteParam
170171
*/
171172

172173
protected function checkForDuplicateParams( $Param, $Params ): void
@@ -175,7 +176,7 @@ protected function checkForDuplicateParams( $Param, $Params ): void
175176
{
176177
if( $Param == $Current[ 'param' ] )
177178
{
178-
throw new RouteParamException( "Duplicate parameter '$Param' found for route {$this->Path}'." );
179+
throw new RouteParam( "Duplicate parameter '$Param' found for route {$this->Path}'." );
179180
}
180181
}
181182
}

src/Routing/RouteParamException.php

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

src/Routing/Router.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,11 @@
22

33
namespace Neuron\Routing;
44

5-
use Neuron\Data\NString;
5+
use Neuron\Core\NString;
66
use Neuron\Log\Log;
7+
use Neuron\Patterns\IRunnable;
78
use Neuron\Patterns\Singleton\Memory;
89

9-
use \Neuron\Patterns\IRunnable;
10-
1110
/**
1211
* Singleton router implementation
1312
*/

tests/unit/RouterTest.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?php
22

3-
use PHPUnit\Framework\TestCase;
43
use Neuron\Routing;
54

65
class RouterTest extends PHPUnit\Framework\TestCase
@@ -56,7 +55,7 @@ function( $parameters )
5655
]
5756
);
5857
}
59-
catch( Routing\RouteParamException $exception )
58+
catch( \Neuron\Core\Exceptions\RouteParam $exception )
6059
{
6160
$Caught = true;
6261
}

version.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"major":0,"minor":6,"patch":6,"build":0}
1+
{"major":0,"minor":6,"patch":7,"build":0}

0 commit comments

Comments
 (0)