Files
mixmaker/backend/internal/adapter/httpapi/server_test.go
lemintare c3624376b0
Some checks failed
CI / backend (push) Has been cancelled
CI / frontend (push) Has been cancelled
CI / compose (push) Has been cancelled
Add Discord guild ID configuration and enhance event announcement options
This commit introduces the `DISCORD_GUILD_ID` environment variable to the configuration files, allowing for better integration with Discord for role synchronization. The event announcement functionality has been updated to include an option for the `@everyone` mention, which can be toggled during event creation. The backend logic has been modified to handle this new option, and corresponding updates have been made to the frontend to allow users to control the mention behavior. Additionally, tests have been added to ensure the correct functionality of these features.
2026-07-19 11:34:11 +03:00

17 lines
473 B
Go

package httpapi
import "testing"
func TestCreateEventRequestDefaultsEveryonePing(t *testing.T) {
if !((createEventRequest{}).options().PingEveryone) {
t.Fatal("legacy create requests without pingEveryone must keep @everyone enabled")
}
}
func TestCreateEventRequestCanDisableEveryonePing(t *testing.T) {
disabled := false
if (createEventRequest{PingEveryone: &disabled}).options().PingEveryone {
t.Fatal("explicit false pingEveryone must disable the ping")
}
}