Skip to content

Commit e4ff973

Browse files
committed
Add even more tests
1 parent 6025a3b commit e4ff973

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

test/datatypes/interval-test.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1971,6 +1971,18 @@ describe('DateTimeInterval', () => {
19711971
should(() => ivl.pointFrom()).throw(Error);
19721972
});
19731973

1974+
it('should return the value for a unit interval with null (max) high bound', () => {
1975+
const ivl = new Interval(MAX_DATETIME_VALUE, null);
1976+
1977+
ivl.pointFrom().should.eql(MAX_DATETIME_VALUE);
1978+
});
1979+
1980+
it('should return the value for a unit interval with null (min) low bound', () => {
1981+
const ivl = new Interval(null, MIN_DATETIME_VALUE);
1982+
1983+
ivl.pointFrom().should.eql(MIN_DATETIME_VALUE);
1984+
});
1985+
19741986
it('should return the point value for a unit interval with limited precision', () => {
19751987
const point = DateTime.parse('2012-01-01');
19761988
const ivl = new Interval(point, point);

0 commit comments

Comments
 (0)