Skip to content

chore: modernise package tooling and drop legacy support - #247

Merged
atymic merged 4 commits into
SocialiteProviders:masterfrom
atymic:chore/modernise-package
Aug 16, 2026
Merged

atymic merged 4 commits into
SocialiteProviders:masterfrom
atymic:chore/modernise-package

Conversation

@atymic

@atymic atymic commented Aug 15, 2026 •

Copy link
Copy Markdown
Member

Modernises the package's dependencies, test tooling and CI matrix.

PHP & Laravel

  • Bump php to ^8.3. 8.2 is security-only until Dec 2026 and receives no bug fixes.
  • Drop illuminate/support: ^11.0, keeping ^12.0 || ^13.0. L11 permits PHP 8.2, which conflicts with the new floor.
  • Bump laravel/socialite to ^5.29.

Testing

  • PHPUnit ^9.0 → ^12.5, and Mockery to ^1.6.
  • Migrate the 28 @test annotations to #[Test] attributes (annotations were removed in PHPUnit 12).
  • Rewrite phpunit.xml.dist for the 12.5 schema, dropping attributes removed in 10+ (convertErrorsToExceptions, backupStaticAttributes, verbose) and moving <coverage><include> to <source>.
  • Declare clientId/clientSecret/redirectUrl on OAuth1\Server. ConfigTrait::setConfig() assigned them without declaration, which is deprecated on PHP 8.4+.
  • Drop a no-op ReflectionProperty::setAccessible() call, deprecated in PHP 8.5.

The suite passes on PHP 8.5 with no deprecations.

Lumen

Removes the Lumen branch from ServiceProvider. Lumen's final release (v11.2.0, Nov 2024) requires illuminate/support: ^11.0, so it can no longer resolve against this package once L11 is dropped — the branch is unreachable.

The SOCIALITEPROVIDERS_STATELESS reads in SocialiteWasCalled and OAuth1\AbstractProvider are deliberately kept, since users may define the constant themselves to force stateless mode. Only the Lumen-specific auto-define is gone.

CI

  • Matrix now runs 8.3, 8.4, 8.5 (was 8.2–8.5), with 8.5 carrying coverage.
  • Drop --no-suggest (a no-op since Composer 2) and phpunit -v (removed in PHPUnit 10).
  • Add a separate Lint workflow running pint --test. pint.json was already committed but was never actually enforced. Pint is installed via setup-php, so it stays out of the package's dependency graph.

⚠️ The new Lint job will fail on this PR. It flags 10 files whose formatting predates this branch and that this PR does not touch. Reformatting them is deliberately left to a follow-up so the diff here stays reviewable. It is a separate workflow specifically so this does not mask the test matrix results.

Docs

Replace the dead Travis and SensioLabsInsight badges with the Actions badge, point Laravel doc links at 13.x, drop two Laravel 5-era Laracasts links, update socialiteproviders.netlify.app links to the live domain, and remove the "Lumen usage is easy" line.


Note: this is a breaking change (PHP floor, L11 drop, Lumen removal) and needs a major version bump.

atymic added 2 commits August 16, 2026 09:56
Require PHP ^8.3 (8.2 is security-only until Dec 2026) and drop the
Laravel 11 constraint, which pinned illuminate/support to a PHP 8.2
floor. Upgrade PHPUnit 9 -> 12.5 and migrate @test annotations to
attributes; 12.5 is the newest major that still supports PHP 8.3.

Remove the Lumen branch from the ServiceProvider. Lumen's final release
(v11.2.0) requires illuminate/support ^11.0, so it can no longer resolve
against this package. The SOCIALITEPROVIDERS_STATELESS reads are kept,
as users may define the constant themselves.

Declare clientId/clientSecret/redirectUrl on OAuth1\Server to fix
dynamic property deprecations on PHP 8.4+.

Run CI on 8.3, 8.4 and 8.5.
Run pint --test in its own Lint workflow rather than as a step in the
test matrix, so a style failure does not mask the test results. Pint is
installed via setup-php instead of require-dev, keeping it out of the
package's dependency graph.
@codecov

codecov Bot commented Aug 16, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 56.72%. Comparing base (a67f194) to head (fa944ca).
⚠️ Report is 11 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #247      +/-   ##
============================================
+ Coverage     55.10%   56.72%   +1.62%     
- Complexity       78       79       +1     
============================================
  Files            10       10              
  Lines           245      238       -7     
============================================
  Hits            135      135              
+ Misses          110      103       -7     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

The rewritten phpunit.xml.dist declared coverage reports unconditionally,
so PHPUnit warned about the missing driver on the 8.3 and 8.4 legs, which
run with coverage disabled. Combined with failOnWarning that aborted the
run before any test executed.

Move the clover and text report flags onto the coverage job instead, and
stop requesting the xdebug extension when coverage is none.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modernises the package for current PHP/Laravel versions by raising the PHP floor, updating key dependencies, migrating the test suite to PHPUnit 12, and simplifying runtime integration by removing unreachable Lumen-specific logic. It also refreshes CI and documentation to match the new support baseline.

Changes:

  • Upgrade runtime + dev dependencies (PHP ^8.3, drop illuminate/support:^11, bump Socialite, PHPUnit 12.5, Mockery 1.6).
  • Update tests/config for PHPUnit 12 (migrate @test → #[Test], refresh phpunit.xml.dist schema, remove deprecated reflection usage).
  • Remove Lumen-specific branches from the service provider; update CI workflows and README links/badges.

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/UserTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
tests/ServiceProviderTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
tests/OAuthTwoTest.php Migrates tests to #[Test], renames test methods, removes deprecated reflection call.
tests/OAuth2ProviderTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
tests/OAuth1ProviderTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
tests/ConfigTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
tests/ConfigRetrieverTest.php Migrates @test to #[Test] for PHPUnit 12 compatibility.
src/ServiceProvider.php Removes Lumen-specific logic; simplifies event firing to Laravel-only path.
src/OAuth1/Server.php Declares config-set properties to avoid dynamic-property deprecations.
README.md Updates badges and links; removes outdated references and Lumen messaging.
phpunit.xml.dist Updates to PHPUnit 12.5 schema; moves coverage include to <source>.
composer.json Raises PHP floor and updates dependency constraints/tooling versions.
.github/workflows/test.yml Updates PHP matrix and PHPUnit invocation; adds explicit coverage run.
.github/workflows/lint.yml Adds Pint lint workflow (currently repository-wide).

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/workflows/lint.yml
@atymic
atymic merged commit 6f176fa into SocialiteProviders:master Aug 16, 2026
5 of 6 checks passed
@atymic atymic mentioned this pull request Aug 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants