Skip to content

Commit

Permalink
provide "meta" as a kwarg. Previously it would work if your factory d…
Browse files Browse the repository at this point in the history
…efined

def factory(value, meta)

but would fail if you wrote the signature as

def factory(value, *, meta)

PiperOrigin-RevId: 608504071
  • Loading branch information
A Googler authored and Blaze Rules Copybara committed Feb 20, 2024
1 parent fd1237c commit 220fb65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/private/expect.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ def _expect_that_value(self, value, *, factory, expr = "value"):
Returns:
A subject corresponding to the type returned by the factory.
"""
return factory(value, self.meta.derive(expr))
return factory(value, meta = self.meta.derive(expr))

def _expect_where(self, **details):
"""Add additional information about the assertion.
Expand Down

0 comments on commit 220fb65

Please sign in to comment.