mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-24 07:39:39 +02:00
fix: Don't show Billings on settings navbar when self-hosted (#1912)
* Do not show billing settings navbar item when self hosted * Do not show billing settings navbar item when self hosted * Add condition to settings helper * Let Stripe::AuthenticationError bubble up
This commit is contained in:
parent
9138bd2b76
commit
624faa10d0
6 changed files with 36 additions and 8 deletions
|
@ -46,6 +46,12 @@ class SettingsTest < ApplicationSystemTestCase
|
|||
assert_selector 'span[data-clipboard-target="iconSuccess"]', visible: true, count: 1 # text copied and icon changed to checkmark
|
||||
end
|
||||
|
||||
test "does not show billing link if self hosting" do
|
||||
Rails.application.config.app_mode.stubs(:self_hosted?).returns(true)
|
||||
open_settings_from_sidebar
|
||||
assert_no_selector "li", text: I18n.t("settings.settings_nav.billing_label")
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def open_settings_from_sidebar
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue