aboutsummaryrefslogtreecommitdiff
path: root/helix-term
diff options
context:
space:
mode:
authorSkyler Hawthorne2023-02-04 21:20:23 +0000
committerGitHub2023-02-04 21:20:23 +0000
commitb2e83f81e10089a0e81ce33c4beb51aefc29a62e (patch)
tree52913187385f31b857e5f1bfcdfe3fe07b008fa5 /helix-term
parentd6e2434f735545ded269f228e3d93684d2be262a (diff)
enable rendering in integration tests (#5819)
This will allow testing more of the code base, as well as enable UI- specific testing. Debug mode builds are prohibitively slow for the tests, mostly because of the concurrency write tests. So there is now a profile for integration tests that sets the optimization level to 2 for a few helix crates, and lowers the number of rounds of concurrent writes to 1000.
Diffstat (limited to 'helix-term')
-rw-r--r--helix-term/src/application.rs4
-rw-r--r--helix-term/tests/test/write.rs2
2 files changed, 1 insertions, 5 deletions
diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs
index 05ceb874..a1685fcf 100644
--- a/helix-term/src/application.rs
+++ b/helix-term/src/application.rs
@@ -277,10 +277,6 @@ impl Application {
Ok(app)
}
- #[cfg(feature = "integration")]
- async fn render(&mut self) {}
-
- #[cfg(not(feature = "integration"))]
async fn render(&mut self) {
let mut cx = crate::compositor::Context {
editor: &mut self.editor,
diff --git a/helix-term/tests/test/write.rs b/helix-term/tests/test/write.rs
index d0128edc..bbf14fc2 100644
--- a/helix-term/tests/test/write.rs
+++ b/helix-term/tests/test/write.rs
@@ -70,7 +70,7 @@ async fn test_write_quit() -> anyhow::Result<()> {
async fn test_write_concurrent() -> anyhow::Result<()> {
let mut file = tempfile::NamedTempFile::new()?;
let mut command = String::new();
- const RANGE: RangeInclusive<i32> = 1..=5000;
+ const RANGE: RangeInclusive<i32> = 1..=1000;
let mut app = helpers::AppBuilder::new()
.with_file(file.path(), None)
.build()?;