Try fixing some doctest errors

This commit is contained in:
Billy Chan 2021-10-31 14:40:36 +08:00
parent 30814f0053
commit fcf3ea9407
No known key found for this signature in database
GPG Key ID: A2D690CAC7DF3CC7
3 changed files with 4 additions and 4 deletions

View File

@ -33,6 +33,7 @@ impl SqlxSqliteConnector {
/// Add configuration options for the SQLite database /// Add configuration options for the SQLite database
pub async fn connect(options: ConnectOptions) -> Result<DatabaseConnection, DbErr> { pub async fn connect(options: ConnectOptions) -> Result<DatabaseConnection, DbErr> {
let mut options = options;
let mut opt = options let mut opt = options
.url .url
.parse::<SqliteConnectOptions>() .parse::<SqliteConnectOptions>()

View File

@ -16,8 +16,8 @@ use std::fmt::Debug;
/// // The code snipped below does an UPDATE operation on a [ActiveValue] /// // The code snipped below does an UPDATE operation on a [ActiveValue]
/// // yielding the the SQL statement ` r#"UPDATE "fruit" SET "name" = 'Orange' WHERE "fruit"."id" = 1"# ` /// // yielding the the SQL statement ` r#"UPDATE "fruit" SET "name" = 'Orange' WHERE "fruit"."id" = 1"# `
/// ///
/// use crate::tests_cfg::{cake, fruit}; /// use sea_orm::tests_cfg::{cake, fruit};
/// use crate::{entity::*, query::*, DbBackend}; /// use sea_orm::{entity::*, query::*, DbBackend};
/// ///
/// Update::one(fruit::ActiveModel { /// Update::one(fruit::ActiveModel {
/// id: ActiveValue::set(1), /// id: ActiveValue::set(1),

View File

@ -17,8 +17,7 @@
/// ``` /// ```
/// #[cfg(feature = "macros")] /// #[cfg(feature = "macros")]
/// ///
/// # use crate::entity::prelude::*; /// # use sea_orm::entity::prelude::*;
/// # use sea_orm_macros::*;
/// use sea_orm::ActiveModelBehavior; /// use sea_orm::ActiveModelBehavior;
/// use sea_orm::RelationDef; /// use sea_orm::RelationDef;
/// use sea_orm::RelationTrait; /// use sea_orm::RelationTrait;