SPlit up
This commit is contained in:
parent
cf39ad754e
commit
f59d01227b
91 changed files with 10370 additions and 7562 deletions
|
|
@ -742,6 +742,29 @@ impl PlaceData {
|
|||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
impl PlaceData {
|
||||
/// Minimal empty instance for integration tests that need an `AppState`
|
||||
/// but never touch place data.
|
||||
pub(crate) fn empty_for_tests() -> Self {
|
||||
PlaceData {
|
||||
name: Vec::new(),
|
||||
name_lower: Vec::new(),
|
||||
name_search: Vec::new(),
|
||||
place_type: InternedColumn::build(&[]),
|
||||
type_rank: Vec::new(),
|
||||
population: Vec::new(),
|
||||
lat: Vec::new(),
|
||||
lon: Vec::new(),
|
||||
city: Vec::new(),
|
||||
travel_destination: Vec::new(),
|
||||
token_index: FxHashMap::default(),
|
||||
token_prefix_index: FxHashMap::default(),
|
||||
fuzzy_trigram_index: FxHashMap::default(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue