Skip to content

Commit

Permalink
drop deprecations (#2065)
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauryD authored Feb 20, 2024
1 parent 5b5fde3 commit aa45bce
Showing 1 changed file with 0 additions and 36 deletions.
36 changes: 0 additions & 36 deletions ember-flatpickr/src/test-support/helpers.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { deprecate } from '@ember/debug';
import { registerHelper } from '@ember/test';
import { find } from '@ember/test-helpers';

/**
Expand Down Expand Up @@ -53,40 +51,6 @@ export function clearFlatpickrDate(selector) {
flatpickrInput._flatpickr.clear(); // eslint-disable-line
}

// Registers helpers for acceptance tests

export default function () {
registerHelper('closeFlatpickrDate', function (app, selector) {
deprecate(
'Using the implicit global helper `closeFlatpickrDate` is deprecated. Please, import it explicitly with `import { closeFlatpickrDate } from "ember-flatpickr/test-support"`',
true,
{ id: 'ember-flatpickr-global-close-flatpickr-date', until: '3.0.0' },
);
return closeFlatpickrDate(selector);
});

registerHelper(
'setFlatpickrDate',
function (app, selector, date, triggerChange) {
deprecate(
'Using the implicit global helper `setFlatpickrDate` is deprecated. Please, import it explicitly with `import { setFlatpickrDate } from "ember-flatpickr/test-support"`',
true,
{ id: 'ember-flatpickr-global-set-flatpickr-date', until: '3.0.0' },
);
return setFlatpickrDate(selector, date, triggerChange);
},
);

registerHelper('clearFlatpickrDate', function (app, selector) {
deprecate(
'Using the implicit global helper `clearFlatpickrDate` is deprecated. Please, import it explicitly with `import { clearFlatpickrDate } from "ember-flatpickr/test-support"`',
true,
{ id: 'ember-flatpickr-global-clear-flatpickr-date', until: '3.0.0' },
);
return clearFlatpickrDate(selector);
});
}

function _throwSelectorError(selector, functionName) {
throw new Error(
`${functionName}() - No input was found using selector '${selector}'`,
Expand Down

0 comments on commit aa45bce

Please sign in to comment.