diff --git a/lib/components/JsonSchema/json-schema.html b/lib/components/JsonSchema/json-schema.html
index ff4000ac..c7865ff6 100644
--- a/lib/components/JsonSchema/json-schema.html
+++ b/lib/components/JsonSchema/json-schema.html
@@ -21,7 +21,7 @@
title="{{schema._displayTypeHint}}">{{schema._displayType}} {{schema._displayFormat}}
{{schema._range}}
- Nullable
+ Nullable
{{enumItem.val | json}}
diff --git a/lib/shared/components/StickySidebar/sticky-sidebar.spec.ts b/lib/shared/components/StickySidebar/sticky-sidebar.spec.ts
index 14a86ecd..43bbaf2e 100644
--- a/lib/shared/components/StickySidebar/sticky-sidebar.spec.ts
+++ b/lib/shared/components/StickySidebar/sticky-sidebar.spec.ts
@@ -27,10 +27,23 @@ describe('Common components', () => {
expect(component).not.toBeNull();
});
- it('should start sticked', () => {
+ it('should start unsticked', () => {
spyOn(component, 'stick').and.callThrough();
+ spyOn(component, 'stickBottom').and.callThrough();
fixture.detectChanges();
- expect(component.stick).toHaveBeenCalled();
+ expect(component.stick).not.toHaveBeenCalled();
+ expect(component.stickBottom).not.toHaveBeenCalled();
+ });
+
+ it('should stick to the top on the next VM tick', (done) => {
+ spyOn(component, 'stick').and.callThrough();
+ spyOn(component, 'stickBottom').and.callThrough();
+ fixture.detectChanges();
+ setTimeout(() => {
+ expect(component.stick).toHaveBeenCalled();
+ expect(component.stickBottom).toHaveBeenCalled();
+ done();
+ });
});
it('should stick if scrolled more than scrollYOffset', () => {
@@ -42,6 +55,8 @@ describe('Common components', () => {
component.updatePosition();
expect(component.stick).toHaveBeenCalled();
});
+
+ // TODO: add tests for stickBottom
});
});