• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

contributte / fileupload / #13

10 Nov 2025 07:47AM UTC coverage: 32.051%. Remained the same
#13

push

github

f3l1x
Fix test suite for contributte/tester migration

This commit fixes all test failures after migrating to contributte/tester:

Test Bootstrap:
- Replaced Ninjify\Nunjuck\Environment with Contributte\Tester\Environment
- Simplified setup to use Environment::setup(__DIR__)

Test Files:
- Updated DefaultFile.phpt to use Contributte\Tester\Toolkit
- Fixed FileUploadExtension.phpt namespace references:
  - Zet\FileUpload\Filter\ImageFilter → Contributte\FileUpload\Filter\ImageFilter
  - Zet\FileUpload\Template\Renderer\Bootstrap4Renderer → Contributte\FileUpload\Template\Renderer\Bootstrap4Renderer
  - Tests\Fixtures\Renderer\InvalidRenderer → Tests\Fixtures\Template\Renderer\InvalidRenderer

PSR-4 Compliance:
- Renamed tests/toolkit → tests/Toolkit (for Tests\Toolkit namespace)
- Renamed tests/fixtures → tests/Fixtures (for Tests\Fixtures namespace)
- This allows PSR-4 autoloading to work correctly

Code Fixes:
- Made DefaultFile properties nullable with default null values
- Fixed ValidUploadModel::rename() return type from void to mixed
  to match parent BaseUploadModel::rename() signature

All tests passing: ✅ 5/5
All QA checks passing: ✅ PHPStan Level 8 + CodeSniffer

50 of 156 relevant lines covered (32.05%)

0.32 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

41.67
/src/Model/DefaultFile.php


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc