mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-29 16:24:26 +01:00
Fix typo and remove useless code in tests
This commit is contained in:
parent
ab4e649221
commit
eabac9676b
@ -61,7 +61,7 @@ impl FileStore {
|
|||||||
|
|
||||||
/// Creates a new temporary update file with the given Uuid.
|
/// Creates a new temporary update file with the given Uuid.
|
||||||
/// A call to `persist` is needed to persist the file in the database.
|
/// A call to `persist` is needed to persist the file in the database.
|
||||||
pub fn new_update_woth_uuid(&self, uuid: u128) -> Result<(Uuid, File)> {
|
pub fn new_update_with_uuid(&self, uuid: u128) -> Result<(Uuid, File)> {
|
||||||
let file = NamedTempFile::new_in(&self.path)?;
|
let file = NamedTempFile::new_in(&self.path)?;
|
||||||
let uuid = Uuid::from_u128(uuid);
|
let uuid = Uuid::from_u128(uuid);
|
||||||
let path = self.path.join(uuid.to_string());
|
let path = self.path.join(uuid.to_string());
|
||||||
|
@ -366,7 +366,7 @@ impl IndexScheduler {
|
|||||||
}
|
}
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
pub fn create_update_file_with_uuid(&self, uuid: u128) -> Result<(Uuid, File)> {
|
pub fn create_update_file_with_uuid(&self, uuid: u128) -> Result<(Uuid, File)> {
|
||||||
Ok(self.file_store.new_update_woth_uuid(uuid)?)
|
Ok(self.file_store.new_update_with_uuid(uuid)?)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn delete_update_file(&self, uuid: Uuid) -> Result<()> {
|
pub fn delete_update_file(&self, uuid: Uuid) -> Result<()> {
|
||||||
@ -726,8 +726,6 @@ mod tests {
|
|||||||
// the "task deletion" task should be marked as "succeeded" and, in its details, the
|
// the "task deletion" task should be marked as "succeeded" and, in its details, the
|
||||||
// number of deleted tasks should be 0
|
// number of deleted tasks should be 0
|
||||||
assert_snapshot!(snapshot_index_scheduler(&index_scheduler));
|
assert_snapshot!(snapshot_index_scheduler(&index_scheduler));
|
||||||
|
|
||||||
handle.dont_block();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
@ -767,8 +765,6 @@ mod tests {
|
|||||||
|
|
||||||
handle.wait_till(Breakpoint::AfterProcessing);
|
handle.wait_till(Breakpoint::AfterProcessing);
|
||||||
assert_snapshot!(snapshot_index_scheduler(&index_scheduler));
|
assert_snapshot!(snapshot_index_scheduler(&index_scheduler));
|
||||||
|
|
||||||
handle.dont_block();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
Loading…
Reference in New Issue
Block a user