We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The best way right now to test an asset sensor required mock.patch:
@mock.patch("dagster.core.instance.DagsterInstance.events_for_asset_key") def test_first_events(mock_events_for_asset_key): mock_events_for_asset_key.side_effect = get_mock_events_for_asset_key( [("comments", 1), ("stories", 2)] ) with tempfile.TemporaryDirectory() as tmpdir_path: context = SensorExecutionContext( instance_ref=InstanceRef.from_dir(tmpdir_path), last_run_key=None, last_completion_time=None, ) requests = story_recommender_sensor.get_execution_data(context) assert len(requests) == 1 assert requests[0].run_key == "1|2"
create_sensor_context(instance=instance_with_events(events))
Excited about this feature? Give it a 👍. We factor engagement into prioritization.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Use Case
The best way right now to test an asset sensor required mock.patch:
Ideas of Implementation
create_sensor_context(instance=instance_with_events(events))
Additional Info
Message from the maintainers:
Excited about this feature? Give it a 👍. We factor engagement into prioritization.
The text was updated successfully, but these errors were encountered: