mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
DEV: replaces topic-notifications-options by DMenu (#30298)
This commit introduces <NotificationsTracking /> which is a wrapper component around <DMenu /> which replaces the select-kit component <TopicNotificationsButton />. Each tracking case has its dedicated component: - topic -> `<TopicNotificationsTracking />` - group -> `<GroupNotificationsTracking />` - tag -> `<TagNotificationsTracking />` - category -> `<CategoryNotificationsTracking />` - chat thread -> `<ThreadNotificationsTracking />`
This commit is contained in:
@ -3,7 +3,7 @@ import { render } from "@ember/test-helpers";
|
||||
import { hbs } from "ember-cli-htmlbars";
|
||||
import { module, test } from "qunit";
|
||||
import { setupRenderingTest } from "discourse/tests/helpers/component-test";
|
||||
import selectKit from "discourse/tests/helpers/select-kit-helper";
|
||||
import notificationsTracking from "discourse/tests/helpers/notifications-tracking-helper";
|
||||
import AutomationFabricators from "discourse/plugins/automation/admin/lib/fabricators";
|
||||
|
||||
module(
|
||||
@ -23,9 +23,7 @@ module(
|
||||
await render(
|
||||
hbs`<AutomationField @automation={{this.automation}} @field={{this.field}} />`
|
||||
);
|
||||
|
||||
await selectKit().expand();
|
||||
await selectKit().selectRowByValue(2);
|
||||
await notificationsTracking().selectLevelId(2);
|
||||
|
||||
assert.strictEqual(this.field.metadata.value, 2);
|
||||
});
|
||||
|
Reference in New Issue
Block a user