You can use mail-tester.com to check your application's e-mails for issues that might cause e-mails to be...
...hard to understand, the helpers available differ for different versions of Rails and the behavior is subtly different. Make sure you read and understand the API before using these...
Background information about session storage in Rails Rails has a default mechanism to store the session in the CookieStore. This...
A general overview about why and how we migrate can be found under Migrating from Elasticsearch to Opensearch
end end def allowed_mime_types %w(image/jpeg image/png) end end This will behave like the solution before: User#portrait will get an expected error message and the User...
...and perform the following exercises. Tip If you've forked your MovieDB in the beginning, Jasmine is already integrated in your code base. Movie counter In Working with the DOM...
...changes it for the current repository. Since it's hard to remember which project behaves how, you should find a suitable global setting. Regardless which option you use you can...
...current branch. Caveat with current For most of us, current is the safest push behavior. However, it has a small side effect: When a branch with your local name does...
In Capistrano 3, your Capfile requires 'capistrano/rails/migrations', which brings two Capistrano tasks: deploy:migrate and deploy:migrating. The former checks...
When MySQL refuses to use your index, there's a number of things that you may be doing wrong. One...
When your code does not behave as expected, you can use a debugger statement ("breakpoint") at any point in your code. This statement will open a REPL ("console") that you...
...the exact line in the code where your expectation does not match the actual behavior. Since we use open source for everything, we can always find that line. When you...
While it might be tempting to set it per project (other devs might benefit from it), you need to do it each time for every project "pollute" a project...
Integration tests give the code its rough form, whereas unit tests pinpoint specific behavior. During development, you are frequently changing levels. It may look something like this: Integration _ ___
...usage example, "happy path"> # Add a scenario for each use case. Examples are: error behavior, access rights, contexts, closer looks at parts of the feature Scenario: ... (This example uses Cucumber...
This is a small example on how you can check if your Postgres index can be used by a specific...
It is just not worth the risk and you can always do better. Alternatives Instead, you should take a different approach. Here are several alternatives.
...rough setting (e.g. open Photos with Shotwell Viewer). If a certain file type (or better mime type) should be opened with a different application, this can be set via command...
There are different kind of memory measurement metrics in Linux. These are the differences: Code Name Description vsz virtual memory...
...to determine if a service can be restarted or not. To manipulate the default behaviour, the package policy-rcd-declarative-allow-all or policy-rcd-declarative-deny-all can be...
...for all exceptions (previously true) :none: It will raise for all exceptions (previous default behavior, value false) Using the new default needs to change a RSpec test like this:
...DSL to define new routes. A big drawback however is that your code often becomes much harder to read. Another con of DSLs is that they tend to be so...
...email => 'foo@bar.de' } book.tobias_kraze # => { :phone => '67890', :email => 'bam@baz.de' } Now change Addressbook so each contact becomes their own Contact instance which responds to #phone and #email: book.henning_koch # => Contact<#....> book.henning_koch.phone...
There are several tools for DNS debugging which offer you more or less information. Most of the time the more...
Deep dive Okay, so the example above has at least one obvious benefit: You do not have to put self.table_name_prefix = "universe_" into each of your classes...
...it. It's not read at all. Here is why (follow links for a better understanding): An ActiveRecord class will pick the table_name_prefix of any of its module...
CarrierWave comes with a set of default configuration options which make sense in most cases. However, you should review these...
available for button, fieldset, input, select, textarea, command, keygen, optgroup, option Browser specific behavior: IE 11: text inputs that are descendants of a disabled fieldset appear disabled but the...
Why do we migrate? Due to a change in licensing, we cannot provide Elasticsearch versions >= 8.0. Version 7.17.x will...