Skip to content

Commit

Permalink
Delete now-unused clearUtils function
Browse files Browse the repository at this point in the history
  • Loading branch information
cmslewis committed Mar 20, 2017
1 parent 8cdb34e commit d869942
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
6 changes: 0 additions & 6 deletions packages/datetime/src/common/dateUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,6 @@ export function clone(d: Date) {
return new Date(d.getTime());
}

export function clearTime(date: Date) {
const day = new Date(date);
day.setHours(0, 0, 0, 0);
return day;
}

export function isDayInRange(date: Date, dateRange: DateRange, exclusive = false) {
if (date == null) {
return false;
Expand Down
7 changes: 0 additions & 7 deletions packages/datetime/test/dateRangeInputTests.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -183,16 +183,9 @@ describe("<DateRangeInput>", () => {
allowSingleDayRange={true}
defaultValue={[START_DATE, END_DATE]}
/>);

// edit the end boundary
getEndInput(root).simulate("focus");

// deselect current end date
getDayElement(END_DAY).simulate("click");

// click on same date as start date
getDayElement(START_DAY).simulate("click");

assertInputTextsEqual(root, START_STR, START_STR);
});

Expand Down

0 comments on commit d869942

Please sign in to comment.