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...
I recommend install Node.js using nvm. This way you can have multiple Node versions in your ~/.nvm. You also won...
There are different kind of memory measurement metrics in Linux. These are the differences: Code Name Description vsz virtual memory...
...the old versions you wish to remove. Keep at least one recent, working kernel besides the one you are currently running. Address Metapackage Conflict (GA vs. HWE)
...a publicly available service) Understand that Safari and mobile Safari (for iOS) usually lag behind other browsers when it comes to feature support. "Transpilation" and "polyfills" are both techniques to...
...ES versions at the top. English MDN Web API Reference MDN is maybe the best reference for JavaScript, HTML and CSS features. Google my-feature mdn is a quick way...
...holds your bash prompt. You might want to change it to serve your needs best. Here is how to: General non-printing escape sequences in your prompt have to be...
Rails partials have a lot of "hidden" features and this card describes some non-obvious usages of Rails Partials.
...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...
...blocks or confusingly sometimes also procs Those with "method semantics", called lambdas lambdas They behave like Ruby method definitions: They are strict about their arguments. return means "exit the lambda...
...the lambda literal -> (since Ruby 1.9.1) test = ->(arg) do puts arg end blocks They behave like do-blocks or simply "segments of code": They try to be smart about their...
There are several tools for DNS debugging which offer you more or less information. Most of the time the more...
Learn to treat files as an ActiveRecord attribute type, like :string or :integer Research Look at the README for...
Why do we migrate? Due to a change in licensing, we cannot provide Elasticsearch versions >= 8.0. Version 7.17.x will...
...instead of using a more costing feature spec. This is especially useful because they become quite convenient when used with Capybara::Node::Finders and Capybara::RSpecMatchers. This allows to wirte...
...view might be too isolated, since view-specs will mock a lot of rails behavior and render the view independent from the controller-logic. Therefore it will be more applicable...
Here is a bash script that I use to auto-configure displays on Ubuntu 24.04 with Xorg. Background
When loading a database dump created with pg_dump into your database, you might run into an error like
If you're responsible for gatekeeping in a projects, here is a guide, what to do. In order to reduce...
Download buttons can be difficult to test, especially with Selenium. Depending on browser, user settings and response headers, one of...
Most forms have a single submit button that will save the record when pressed. Sometimes a form needs additional submit...
...requestAnimationFrame can be used to reduce the number of repaints for animations. This might benefit your application performance. Read Don't throw exceptions from async functions What Color Is Your...
...helperFunction? What happens when you remove the await of init? What causes the new behavior? Now have a look at this sketched usage of asynchronous functions: const news = await fetchNews...
Understand how nested attributes appear in the params. See how the Rails form helpers encode the names of nested...
The DB schema is the most important source of truth for your application and should be very self-explanatory. If...
It might sometimes be useful to check whether your Rails application accesses the file system unnecessarily, for example if your...
...no longer recommend this option. After a chrome update, the chromedriver package sometimes lags behind and is not compatible. Install via apt install chromium-chromedriver Option 3: Install via npm...
...no longer recommend this option. After a chrome update, the chromedriver package sometimes lags behind and is not compatible. There's a handy npm package. sudo npm -g install chromedriver...
When a user shares your content, a snippet with title, image, link and description appears in her timeline. By default...