pub fn expect_build(
        self,
        crate_id: i32,
        published_by: i32,
        connection: &PgConnection,
    ) -> Version {
        self.build(crate_id, published_by, connection)
            .unwrap_or_else(|e| {
                panic!("Unable to create version: {:?}", e);
            })
    }
/// Consumes the builder and creates the version record in the database.
///
/// # Panics
///
/// Panics (and fails the test) if any part of inserting the version record fails.
Consumes the builder and creates the version record in the database.
Consumes the builder and creates the version record in the database .
pub fn expect_build(
        self,
        crate_id: i32,
        published_by: i32,
        connection: &PgConnection,
    ) -> Version {
        self.build(crate_id, published_by, connection)
            .unwrap_or_else(|e| {
                panic!("Unable to create version: {:?}", e);
            })
    }
pub fn expect_build ( self , crate_id : i32 , published_by : i32 , connection : & PgConnection , ) -> Version { self . build ( crate_id , published_by , connection ) . unwrap_or_else ( | e | { panic ! ( " " e ) ; } ) }
Consumes the builder and creates the version record in the database.
Consumes the builder and creates the version record in the database .
self
crate_id
i32
published_by
i32
connection
&PgConnection
panics
Panics (and fails the test) if any part of inserting the version record fails.
Panics ( and fails the test ) if any part of inserting the version record fails .