Closed Anbranin closed 7 years ago
😱
Yeah I realize that now. I also realize I should have realized it was obvious that I was accessing the file correctly given that a 'permission denied' error occurred earlier. I cannot tell if Travis is actually running the script, though, since I see no output. Am I supposed to? I made, as you can see, a test script that just echos. If it's getting run, should I see it in the build log, or is it normal that I don't? I've read the entire first page of several Google searches and it appears I'm doing this correctly. If I am and the scripts are indeed just getting silently run, then the problem lies in, perhaps, the placement of the script, or the migration not getting run correctly or in the right spot, or any number of things. It's just frustrating running a migration and then being told I need to run a migration.
So 3 things to mention, as there appears to be a bit on confusion here.
chmod
) every Travis run. The script can just be executable in the git repository. Git tracks file permissions too, so just chmod it on your computer and commit that.before_script:
- scripts/test.sh
{
"language": "ruby",
"rvm": "2.3.1",
"env": "RAILS_VERSION=4",
"gemfile": "gemfiles/rails_5.gemfile",
}
Oh, and as far as whether to place your stuff in script
or before_script
:
before_script
is part of the setup - it's stuff that needs to happen before we can even begin to test our software. If anything fails in that step, the build halts as an error becuase we can't run our tests.
script
actually is the test step - it's stuff that determines whether our tests currently pass. If anything fails in that step, the build continues (so we can see everything that's wrong), but the build will be a failure.
all the keys are strings now due to syntax change
This seems incorrect. That is, I don't think you should change the behavior of the application to accommodate an old version of ruby. As a reminder, the following are all hashes with symbols for keys:
# The *only* valid syntaxes in ruby 1.8.7
{ :key => 'value' }
{ :'key' => 'value' }
# Also valid in ruby 1.9+
{ key: 'value' }
# Also valid in ruby 2.2+
{ 'key': 'value' }
@Anbranin, can we close?
UGh yes
I mean don't merge this, but I could use some input. Please for the love of God help me.