feat: 🎸 add helper text option to checkbox component

This commit is contained in:
Randall Morey committed 2021-05-21 14:12:48 -04:00
1 parent fde633331c
commit 7e6158b847
6 files changed
+43 -13

No files matched your search

@@ -30,6 +30,17 @@ module('Integration | Component | rose/form/checkbox', function (hooks) {
assert.ok(await find('input'));
});
test('it renders optional helper text', async function (assert) {
assert.expect(1);
await render(
hbs`<Rose::Form::Checkbox @label="Label" @helperText="Hello world" />`
);
assert.equal(
await find('.rose-form-helper-text').textContent.trim(),
'Hello world'
);
});
test('it displays optional errors', async function (assert) {
await render(hbs`
<Rose::Form::Checkbox @error={{true}} as |field|>