File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed
Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -219,7 +219,7 @@ impl Client {
219219 /// use futures::StreamExt;
220220 /// # use serde_json::json;
221221 /// # tokio_test::block_on(async {
222- /// # let container = eventsourcingdb::container::Container::start_default ().await.unwrap();
222+ /// # let container = eventsourcingdb::container::Container::start_preview ().await.unwrap();
223223 /// let db_url = "http://localhost:3000/";
224224 /// let api_token = "secrettoken";
225225 /// # let db_url = container.get_base_url().await.unwrap();
Original file line number Diff line number Diff line change @@ -169,14 +169,25 @@ impl Container {
169169 /// Shortcut method to start the container with default settings.
170170 ///
171171 /// This is the same as calling [`Container::builder`] and then [`ContainerBuilder::start`].
172- /// In most cases this will create a contaienr with the latest image tag and a working configuration.
172+ /// In most cases this will create a container with the latest image tag and a working configuration.
173173 ///
174174 /// # Errors
175175 /// This functions returns the errors of [`ContainerBuilder::start()`]
176176 pub async fn start_default ( ) -> Result < Container , ContainerError > {
177177 Self :: builder ( ) . start ( ) . await
178178 }
179179
180+ /// Shortcut method to start the container with the preview tag and default settings.
181+ ///
182+ /// This is the same as calling [`Container::builder`], [`Container::with_image_tag("preview")`] and then [`ContainerBuilder::start`].
183+ /// In most cases this will create a container with the latest image tag and a working configuration.
184+ ///
185+ /// # Errors
186+ /// This functions returns the errors of [`ContainerBuilder::start()`]
187+ pub async fn start_preview ( ) -> Result < Container , ContainerError > {
188+ Self :: builder ( ) . with_image_tag ( "preview" ) . start ( ) . await
189+ }
190+
180191 /// Get the host of the container.
181192 ///
182193 /// This is the host that you can use to connect to the database. In most cases this will be `localhost`.
You can’t perform that action at this time.
0 commit comments