Skip to content

Commit

Permalink
Make bin/rails executable (hotwired#238)
Browse files Browse the repository at this point in the history
* Make `bin/rails` executable:

This commit contains the results of:

```sh
chmod a+x bin/rails
```

* Use `bin/test` in CI

Use `bin/test` with a pattern for finding files instead of `bundle exec
rake`. We're passing a pattern to `bin/test` because without it, tests
in `test/system` are skipped:

For example:

```
~/Work/hotwired/turbo-rails bin-rails-execution-permissions*                                                              [7/2071]
❯ bin/test
Installing Ruby dependencies
Warning: the running version of Bundler (2.2.12) is older than the version that created the lockfile (2.2.16). We suggest you to u
pgrade to the version that created the lockfile by running `gem install bundler:2.2.16`.
Installing JavasScript

app/javascript/turbo/index.js → app/assets/javascripts/turbo.js...
created app/assets/javascripts/turbo.js in 692ms
Migrating test database
Run options: --seed 2063

Running:

.............................................................

Finished in 0.612377s, 99.6118 runs/s, 174.7290 assertions/s.
61 runs, 107 assertions, 0 failures, 0 errors, 0 skips

~/Work/hotwired/turbo-rails bin-rails-execution-permissions* 7s
❯ gs
 ## bin-rails-execution-permissions
 M test/system/broadcasts_test.rb

~/Work/hotwired/turbo-rails bin-rails-execution-permissions*
❯ gd
diff --git a/test/system/broadcasts_test.rb b/test/system/broadcasts_test.rb
index 38a349e..9aa6e54 100644
--- a/test/system/broadcasts_test.rb
+++ b/test/system/broadcasts_test.rb
@@ -2,6 +2,7 @@ require "application_system_test_case"

 class BroadcastsTest < ApplicationSystemTestCase
   test "Message broadcasts Turbo Streams" do
+    fail
     visit messages_path
```
  • Loading branch information
seanpdoyle authored Sep 17, 2021
1 parent 39ce079 commit 65a4e19
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ jobs:

- name: Run tests
run: |
bundle exec rails db:test:prepare
bundle exec rake
bin/rails db:test:prepare
bin/test test/**/*_test.rb
Empty file modified bin/rails
100644 → 100755
Empty file.

0 comments on commit 65a4e19

Please sign in to comment.