1
0
Fork 0
mirror of https://github.com/binwiederhier/ntfy.git synced 2025-12-02 05:10:06 +01:00

Make it easy to build without Stripe

This commit is contained in:
binwiederhier 2025-08-07 16:41:39 +02:00
parent 32fa8d43c1
commit ea338ae4fa
11 changed files with 89 additions and 41 deletions

View file

@ -4,8 +4,8 @@ import (
"database/sql"
"fmt"
"github.com/stretchr/testify/require"
"github.com/stripe/stripe-go/v74"
"golang.org/x/crypto/bcrypt"
"heckel.io/ntfy/v2/payments"
"heckel.io/ntfy/v2/util"
"net/netip"
"path/filepath"
@ -164,8 +164,8 @@ func TestManager_AddUser_And_Query(t *testing.T) {
require.Nil(t, a.ChangeBilling("user", &Billing{
StripeCustomerID: "acct_123",
StripeSubscriptionID: "sub_123",
StripeSubscriptionStatus: stripe.SubscriptionStatusActive,
StripeSubscriptionInterval: stripe.PriceRecurringIntervalMonth,
StripeSubscriptionStatus: payments.SubscriptionStatusActive,
StripeSubscriptionInterval: payments.PriceRecurringIntervalMonth,
StripeSubscriptionPaidUntil: time.Now().Add(time.Hour),
StripeSubscriptionCancelAt: time.Unix(0, 0),
}))