})
it('should test isLast functions', () =>{
- component.formFieldsListObj.length = 4;
- expect(component.isLast(3)).toEqual(true);
+ component.formFieldsListObj = [1,2,3,4,5];
+ let test: Boolean = component.isLast(3);
+ expect(test).toEqual(false);
})
+
+ it('should test isFirst function', () => {
+ let test: Boolean = component.isFirst(0);
+ expect(test).toEqual(true);
+ })
+
+ it('should test ngDoCheck', () => {
+ component.sqlAsDefaultValue = true;
+ component.ngDoCheck();
+ expect(component.showDefaultSQLOption).toEqual(true);
+ })
+
});