Don't add to host exposed during roc test

This commit is contained in:
Ayaz Hafiz 2022-09-12 14:14:54 -04:00
parent b0ab69d41c
commit 44772b8f3d
No known key found for this signature in database
GPG key ID: 0E2A37416A25EF58

View file

@ -2405,7 +2405,11 @@ fn update<'a>(
Some(ref platform_data) => module_id == platform_data.module_id,
};
if is_host_exposed {
let add_to_host_exposed = is_host_exposed &&
// During testing, we don't need to expose anything to the host.
!matches!(state.exec_mode, ExecutionMode::Test);
if add_to_host_exposed {
state.exposed_to_host.values.extend(
solved_module
.exposed_vars_by_symbol