You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -76,7 +76,7 @@ cd demo
76
76
bundle exec rails test:all # or test:system
77
77
```
78
78
79
-
The [Docker development environment](#using-docker compose) appears to generate screenshots that are the same as what GitHub generates.
79
+
The [Docker development environment](#developing-with-docker) appears to generate screenshots that are the same as what GitHub generates.
80
80
81
81
Finally, maintainers may sometimes push changes directly to `main` or use other workflows to update the code. If pushing to `main` generates a commit for screenshot changes, please consider reverting your change immediately by executing the above `pull` and `revert` and another `push`, for the sanity of users who are using the edge (`main` branch) version of the gem. At any rate, review the changes promptly and use your judgement.
Copy file name to clipboardExpand all lines: DOCKER.md
+27-7Lines changed: 27 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,12 +12,10 @@ Put your personal and OS-specific configuration in a `compose.override.yml` file
12
12
The following instructions work for an Ubuntu host, and will probably work for other common Linux distributions. Add a `compose.override.yml` in the local directory, that looks like this:
# You have to set the user and group for this process, because you're going to be
22
20
# creating all kinds of files from inside the container, that need to persist
23
21
# outside the container.
@@ -50,23 +48,45 @@ docker compose up -d
50
48
You may need to install or update the gems:
51
49
52
50
```bash
53
-
docker compose exec-it shell bundle install
51
+
docker compose execweb bundle install
54
52
```
55
53
56
54
To get a shell in the container:
57
55
58
56
```bash
59
-
docker compose exec -it shell /bin/bash
57
+
docker compose exec web /bin/bash
58
+
```
59
+
60
+
Once in the shell, run tests:
61
+
62
+
```bash
63
+
bundle exec rake test
60
64
```
61
65
62
-
Once in the shell:
66
+
Run the demo app and browse to it:
67
+
68
+
```bash
69
+
cd demo
70
+
bin/dev
71
+
```
72
+
73
+
On the host, not the Docker container, get the port number(s) you can use in the browser to access the test app running in the Docker container:
74
+
75
+
```bash
76
+
docker compose port web 3001 | cut -d: -f 2 # Browser
77
+
docker compose port web 7900 | cut -d: -f 2 # To watch the browser execute system tests.
78
+
```
79
+
80
+
Browse to `localhost:<port number from above>`.
81
+
82
+
Run system tests:
63
83
64
84
```bash
65
85
cd demo
66
86
bundle exec rails test:system
67
87
```
68
88
69
-
Note that this system test approach is highly experimental and has some rough edges. The docker compose file and/or steps to run system tests may change. The tests currently fail, because the files with which they're being compared were generated on a Mac, but the Docker containers are running Linux.
89
+
Note that this system test approach is highly experimental and has some rough edges. The docker compose file and/or steps to run system tests may change.
0 commit comments