MCPcopy Create free account
hub / github.com/hashintel/hash / attach_future

Function attach_future

libs/error-stack/tests/test_change_context.rs:78–90  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

76
77#[test]
78fn attach_future() {
79 let future = create_future()
80 .change_context(ContextA(0))
81 .attach_opaque(AttachmentA)
82 .change_context_lazy(|| ContextB(0))
83 .attach_opaque_with(|| AttachmentB);
84
85 let error = futures::executor::block_on(future);
86
87 let report = error.expect_err("Not an error");
88 test_messages(&report);
89 test_kinds(&report);
90}

Callers

nothing calls this directly

Calls 10

create_futureFunction · 0.85
ContextAClass · 0.85
ContextBClass · 0.85
block_onFunction · 0.85
test_messagesFunction · 0.70
test_kindsFunction · 0.70
attach_opaque_withMethod · 0.45
change_context_lazyMethod · 0.45
attach_opaqueMethod · 0.45
change_contextMethod · 0.45

Tested by

no test coverage detected