• Takashi Sakamoto's avatar
    Revert "[fuchsia] Allow the process' ComponentContext to be overridden by tests." · de3cd134
    Takashi Sakamoto authored
    This reverts commit 12dc6d4e.
    
    Reason for revert: suspect causing compile failure on fuchsia-x64-dbg
    
    Sample build: https://ci.chromium.org/p/chromium/builders/ci/fuchsia-x64-dbg/7443
    
    Sample log: https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket.appspot.com/8887344967367021984/+/steps/compile/0/stdout?format=raw
    ---
    ld.lld: error: undefined symbol: sys::ComponentContext::ComponentContext(std::__Cr::shared_ptr<sys::ServiceDirectory>, zx::channel, async_dispatcher*)
    >>> referenced by test_component_context_for_process.cc
    >>>               test_support/test_component_context_for_process.o:(std::__Cr::__unique_if<sys::ComponentContext>::__unique_single std::__Cr::make_unique<sys::ComponentContext, std::__Cr::shared_ptr<sys::ServiceDirectory>, zx::channel>(std::__Cr::shared_ptr<sys::ServiceDirectory>&&, zx::channel&&)) in archive obj/base/test/libtest_support.a
    
    ld.lld: error: undefined symbol: sys::ServiceDirectory::ServiceDirectory(fidl::InterfaceHandle<fuchsia::io::Directory>)
    >>> referenced by test_component_context_for_process.cc
    >>>               test_support/test_component_context_for_process.o:(std::__Cr::__unique_if<sys::ServiceDirectory>::__unique_single std::__Cr::make_unique<sys::ServiceDirectory, fidl::InterfaceHandle<fuchsia::io::Directory> >(fidl::InterfaceHandle<fuchsia::io::Directory>&&)) in archive obj/base/test/libtest_support.a
    >>> referenced by test_component_context_for_process.cc
    >>>               test_support/test_component_context_for_process.o:(std::__Cr::__compressed_pair_elem<sys::ServiceDirectory, 1, false>::__compressed_pair_elem<fidl::InterfaceHandle<fuchsia::io::Directory>&&, 0ul>(std::__Cr::piecewise_construct_t, std::__Cr::tuple<fidl::InterfaceHandle<fuchsia::io::Directory>&&>, std::__Cr::__tuple_indices<0ul>)) in archive obj/base/test/libtest_support.a
    
    ld.lld: error: undefined symbol: sys::ComponentContext::~ComponentContext()
    >>> referenced by test_component_context_for_process.cc
    ...
    ---
    
    
    
    Original change's description:
    > [fuchsia] Allow the process' ComponentContext to be overridden by tests.
    > 
    > ComponentContextForCurrentProcess() returns a sys::ComponentContext
    > connected to the process' incoming service directory, outgoing directory
    > for services & debugging APIs, etc.
    > 
    > Provide a TestComponentContextForProcess, which overrides the process'
    > ComponentContext with one which by default has no services available,
    > and which allows services to be provided by the test itself, and for
    > services available in the test process environment to be exposed to the
    > test.
    > 
    > Bug: 1038786
    > Change-Id: I0d754a1629ab25527dce377d6ffaa039791ef3e1
    > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2064908
    > Reviewed-by: Sergey Ulanov <sergeyu@chromium.org>
    > Commit-Queue: Sergey Ulanov <sergeyu@chromium.org>
    > Auto-Submit: Wez <wez@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#744858}
    
    TBR=wez@chromium.org,kpozin@google.com,sergeyu@chromium.org,anmittal@google.com,geb@google.com
    
    Change-Id: Ieb24627ff5605b72ce3c6ca8dca7c1979dc77102
    No-Presubmit: true
    No-Tree-Checks: true
    No-Try: true
    Bug: 1038786
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2076741Reviewed-by: default avatarTakashi Sakamoto <tasak@google.com>
    Commit-Queue: Takashi Sakamoto <tasak@google.com>
    Cr-Commit-Position: refs/heads/master@{#744909}
    de3cd134
BUILD.gn 135 KB