Skip to content

Conversation

@rojtjo
Copy link
Contributor

@rojtjo rojtjo commented Sep 11, 2024

This PR adds support for named and lazy values.

use FeatureNinja\TestingMatrix\Matrix;
use FeatureNinja\TestingMatrix\Value;

Matrix::create([
    'version' => [
        Value::of('8.3', 8.3),
        Value::of('8.4', fn () => 8.3),
    ],
    'data' => [
        Value::lazy('large-file', fn () => file_get_contents('/some/path'),
    ],
])

@rojtjo rojtjo merged commit b3c8082 into main Sep 11, 2024
4 checks passed
@rojtjo rojtjo deleted the feature/named-and-lazy-values branch September 11, 2024 15:52
@codecov
Copy link

codecov bot commented Sep 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Files with missing lines Coverage Δ Complexity Δ
src/Matrix.php 100.00% <100.00%> (ø) 7.00 <0.00> (+1.00)
src/Value.php 100.00% <100.00%> (ø) 5.00 <5.00> (?)

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