396 Commits

Author SHA1 Message Date
Stefan Grootscholten d42c8731f0 Fix issue that local part parser uses remaining code from lexer (#409)
Without this fix the added test will output

1) Egulias\EmailValidator\Tests\EmailValidator\EmailParserTest::testMultipleEmailAddresses
Failed asserting that two strings are identical.
--- Expected
+++ Actual
@@ @@
-'another-local-part'
+'some-random-but-large-domain-part.example.comanother-local-part'
4.0.4
2025-03-06 23:45:56 +01:00
Eduardo Gulias Davis 515346048d Different strategy 2024-12-31 16:29:41 +01:00
Eduardo Gulias Davis 4fc3f5c419 Different strategy 2024-12-31 16:26:39 +01:00
Eduardo Gulias Davis 7dc3b8de4c Coverage path (#401)
* coverage path

* Use different action
2024-12-31 16:15:01 +01:00
Cari D. Burstein 3bd9c8c802 Update NoDNSRecord.php (#395)
Fixed typo in No DNS Record reason
2024-12-31 15:41:19 +01:00
Eduardo Gulias Davis 8be1dae097 Polish (#400)
* Polish

* polish

* improve workflow

* Fix action usage

* polish

* polish
2024-12-31 15:39:18 +01:00
Eduardo Gulias Davis dcf8f79c41 polish 2024-12-27 23:41:39 +01:00
Eduardo Gulias Davis e30356b45e Fix action usage 2024-12-27 23:22:30 +01:00
Eduardo Gulias Davis 229560066e improve workflow 2024-12-27 23:11:08 +01:00
Eduardo Gulias Davis 1ed7ade52c Update to recommended two workflows for secure secret when uploadin (#399)
* Update to recommended two workflows for secure secret when uploadin

* Making depenant workflow work
2024-12-27 22:52:06 +01:00
Eduardo Gulias Davis 793eb01a3f Fix for secrets on PRs 2024-12-27 20:22:03 +01:00
Eduardo Gulias Davis 32b52d9e08 Test for #317 (#397) 2024-12-27 20:21:18 +01:00
Eduardo Gulias Davis b115554301 Fix Readme style 4.0.3 2024-12-27 01:36:43 +01:00
Eduardo Gulias Davis c67e8e655f Fix Readme style 2024-12-27 01:27:39 +01:00
Eduardo Gulias Davis 2647beedf3 Removed stale changelog 2024-12-27 01:17:25 +01:00
Eduardo Gulias Davis e25ccf7e74 Add depandabot 2024-12-27 00:36:05 +01:00
Eduardo Gulias Davis d379dc240b Update readme 2024-12-27 00:31:08 +01:00
Eduardo Gulias Davis 621d46003b Fix github action (#396)
* Fix github action

* PHP8.4 is too new

* Revert log storage
2024-12-27 00:28:29 +01:00
chris 87db43e4ff docs: fix build status in README.md (#392) 2024-10-16 23:10:38 +02:00
chris c118cc7666 ci: fix deprecation for github actions (#391) 2024-10-08 19:20:25 +02:00
Arnt Gulbrandsen b4a1a0e5a6 Regularise a test. (#389)
The validEmailsProvider contained n-1 valid email addresses and 1 domain;
this replaces the domain with two valid email addresses in that domain, so
that all entries match the name.
2024-09-15 22:03:00 +02:00
Danny van der Sluijs 92c1ab0cc1 Update GitHub Actions to V4 (#383)
* Update tests.yml using actions/checkout@v4

* Update static-analysis.yml usingactions/checkout@v4
2024-05-01 15:20:12 +02:00
Daniel 8775776563 chore: replace scalar with more precise type specification (#369)
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2023-10-22 23:56:40 +02:00
Andrew Ivchenkov 87b8b8506e Used the most strict psalm level and fixed all psalm errors (#377) 2023-10-15 23:39:26 +02:00
Christian Rishøj ebaaf5be6c perform AAAA check separately (fixes #301) (#376) 4.0.2 2023-10-06 08:47:41 +02:00
chris d11195e117 chore: add tests for php 8.3 (#373)
authored-by: Christopher Georg <christopher.georg@sr-travel.de>
2023-08-28 18:30:37 +02:00
chris 36233f5918 chore: update phpunit 9 = 10 and psalm 4 = 5 (#368)
Co-authored-by: Christopher Georg <christopher.georg@sr-travel.de>
2023-07-28 20:33:18 +02:00
Márk Magyar 27be0e7157 code refactor (#364)
* use spread syntax instead of array_merge()

* use type cast instead of function cast

* removed redundant returns

* removed redundant phpdoc - type is already inferred

* removed invalid phpdoc - type is already inferred

The PHPDoc return type hint was incomplete, it should have been `InvalidEmail|null`, however, it can be removed altogether as the return type is already inferred from the code.

* changed warnEscaping()'s return value from bool to void

This is not a breaking change as the method is private,  and it's only used at one place, where the return value was not used anyway.

* made private class property local

`private $parser` was used in only one place, hence it can be local, there is no reason to put it into the class' scope.

* removed unnecessary type casting

Concatenation already casts `static::CODE` from `int` to `string`, no reason to do it explicitly.

* removed redundant initializers - constructor overwrites them immediately

* removed redundant else block

* simplified if-else statement

* wrapped if body in brackets to comply with PSR12

* fixed README formatting

- fixed numbering at the `Available validations` section
- fixed overall formatting

* Revert "removed redundant phpdoc - type is already inferred"

This reverts commit 68a9ae20bd.

* don't wrap long lines

* make properties typed

Also using constructor property promotion, see more info about it [here](https://php.watch/versions/8.0/constructor-property-promotion).
2023-06-07 16:47:52 +02:00
Eduardo Gulias Davis 97c28cd611 Badges and Scrutinezr config (#366)
* Codacy badges and removing Scrutinizr config
2023-05-23 22:25:38 +02:00
Eduardo Gulias Davis 178d148438 Codacy GitHub action (#365)
* README for v4

* badges update

* license year

* Adding codacy reporter action

* plain text secret for testing

* using bash

* downloading artifact

* all in one

* path to coverage

* removing extra job and adding sending coverage report only once
2023-05-23 17:55:24 +02:00
Grégoire Pineau c4f65a68ee Fixed typo in CHANGELOG.md (#363) 2023-05-22 16:53:31 +02:00
KergeKacsa 3a85486b70 DNS record check now passes if email address has no top-level domain (#355) 4.0.1 2023-01-14 15:17:03 +01:00
Eduardo Gulias Davis db4c31490b V4 readme updates (#353)
* README for v4
4.0.0
2023-01-07 12:14:40 +01:00
Alexander M. Turek 17865e0fb7 Fix Lexer 2 compatibility (#349) 2023-01-02 23:13:52 +01:00
Eduardo Gulias Davis 2a096c7219 Behold the birth of v4! 2023-01-02 19:01:12 +01:00
Eduardo Gulias Davis 28e911fa56 Resolve conflicts for v4 first commit 2023-01-02 19:00:18 +01:00
Dries Vints b531a23117 GitHub Actions (#348)
* Add GitHub Actions workflow

* Ignore composer.lock

* Separate static analysis build

* Use ramsey/composer-install

* Add 7.2 and 7.3

* Remove coveralls
3.2.5
2023-01-02 18:26:14 +01:00
Alexander M. Turek 5f35e41eba Allow doctrine/lexer 2 (#345) 3.2.4 2022-12-30 15:09:25 +01:00
Bastien Wermeille b3a424f63d loosen constraint over lexer 2022-12-29 12:17:25 +01:00
Bastien Wermeille d25d60679b Fix readme + clean composer.json 2022-12-28 23:06:42 +01:00
Bastien Wermeille 4898bc2528 Fix psalm type check 2022-12-18 23:38:43 +01:00
Bastien Wermeille 4665415250 Fix psalm type issues info 2022-12-18 23:33:57 +01:00
Bastien Wermeille 7771e2bf2c Fix types issues 2022-12-18 22:43:52 +01:00
Bastien Wermeille f9e4bc5835 Use php nullsafe operator to fix type issues 2022-12-18 22:04:37 +01:00
Bastien Wermeille 0841364b8d Upgrade to doctrine/lexer 3.x 2022-12-18 21:51:37 +01:00
Bastien Wermeille 3d25492123 Fix Tests + Psalm issues 2022-12-15 00:04:10 +01:00
Bastien Wermeille d80748070a Apply feedbacks 2022-12-14 20:29:41 +01:00
Bastien Wermeille 86933da4bb Migrate to doctrine/lexer v2.0 2022-12-14 14:12:31 +01:00
Alexis Lefebvre 0170967656 CHANGELOG: Fix typo “Breacking” (#333) 3.2.3 2022-09-03 11:54:08 +02:00
Eduardo Gulias Davis 4c72190f32 Update LICENSE 2022-08-14 20:36:33 +02:00