Unit testing – onGridReady – Ag-grid event in Angular

I am having a function like below in my component file like below

  onGridReady(params) {
    this.gridApi = params.api;
    this.columnApi = params.columnApi;

For the above function i am writing the spec like the below one

describe('#onGridReady()', () => {
    const params = {
      api: new MockGridApi(),
      ColumnApi: new MockColumnApi(),

    it('call the function', () => {
      spyOn(component, 'onGridReady').and.callThrough();


The spec passes as well as the coverage is done for the above function. But i would like to know whether is it the correct way or writing the spec or do i need to write more specs like to sizeColumnsToFit() has been called etc.,
Could anyone can give your view about it.

Source: Angular Questions