Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updated steps md #2

Merged
merged 1 commit into from
Jun 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions step-3-local-development-environment.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ So, add the following dependencies as well:
```

## Create ContainersConfig class under src/test/java
Let's create `ContainersConfig` class under `src/test/java` to configure the required containers.
Let's create `com.testcontainers.catalog.ContainersConfig` class under `src/test/java` to configure the required containers.

```java
package com.testcontainers.catalog;
Expand Down Expand Up @@ -143,7 +143,7 @@ Let's understand what this configuration class does:
* We also configured an `ApplicationRunner` bean to create the AWS resources like S3 bucket upon application startup.

## Create TestApplication class under src/test/java
Next, let's create a `TestApplication` class under `src/test/java` to start the application with the Testcontainers configuration.
Next, let's create a `com.testcontainers.catalog.TestApplication` class under `src/test/java` to start the application with the Testcontainers configuration.

```java
package com.testcontainers.catalog;
Expand Down Expand Up @@ -189,7 +189,7 @@ You should get a response similar to the following:
### Upload Product Image
```shell
curl -X "POST" 'http://localhost:8080/api/products/P101/image' \
--form 'file=@"/Users/siva/work/product-p101.jpg"'
--form 'file=@"src/test/resources/P101.jpg"'
```

You should see a response similar to the following:
Expand Down
6 changes: 6 additions & 0 deletions step-4-connect-to-services.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,12 @@ with the following connection properties:
psql -h localhost -p 5432 -U test -d test
```

If you authenticate with the default password `test` you should be able to and run the following SQL query to check the products:

```sql
select * from test.public.products;
```

Similarly, you can connect to any of your containers using the same approach by using the port-mapping feature of Testcontainers Desktop.

###
Expand Down
Loading