Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Split RLS into bin/lib and move some tests to Cargo integration test format #1210

Merged
merged 14 commits into from
Jan 8, 2019

Conversation

Xanewok
Copy link
Member

@Xanewok Xanewok commented Dec 22, 2018

This cleans up our testing infrastructure and allows integration tests to test the library directly (just like old tests did) and end-to-end (like the new ones, where we spawn a process and communicate with it via stdio).

Summary:

  • Build RLS with FIXTURES_DIR env var set at compile time so unit tests and integration tests have a unified definition
  • Split RLS into bin/lib and clean up some module hierarchy
  • Move old src/test/mod.rs to tests/tests_old.rs
  • Move tooltip tests in src/actions/hover.rs to dedicated tests/tooltip.rs (harness was setting up and starting an entire server per test so that was an integration-style test anyway)

What's still to be done is to unify the way we check both tests/tests{,_old}.rs test suites in preparation for declarative tests - preferably spawning rls like in the new suite but use the typed messages from the library, like in the old suite.

@Xanewok Xanewok force-pushed the split-bin-lib branch 2 times, most recently from b23cd72 to 93fee34 Compare January 4, 2019 14:39
Copy link
Member

@nrc nrc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, could you rebase then merge please?

@Xanewok Xanewok merged commit aa70e88 into rust-lang:master Jan 8, 2019
@Xanewok
Copy link
Member Author

Xanewok commented Jan 8, 2019

Done, thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants