Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for named and lazy values #8

Merged
merged 3 commits into from
Sep 11, 2024
Merged

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
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.

1 participant