GitlabCI staged pipeline continues even when one the the stages fails?

I thoght that pipeline should stop when one of the stages fails.

Please see the provide screenshot

Here is simple snippet of my gitlab_ci.yml that should fail but continues without any problem

stages:

  • test
  • tag
  • build

fail-job:
image: node:lts
stage: test
allow_failure: false
script:
- ls no-file.txt

The tag and build stages are even though the test stage returns error.
Thanks for any help

Solved

I needed to set
rules:
when: on_success
on the next stage, instead of when: always