I cannot pass the last condition.
I get NullPointerException when I run the verification. I suppose that I haven't done everything correctly in the controller:
public void onShowAllUsers(){
model.loadUsers();
usersView.refresh(model.getDataModel());
}
Can someone please help?
package com.codegym.task.task36.task3608;
import com.codegym.task.task36.task3608.bean.User;
import com.codegym.task.task36.task3608.model.FakeModel;
import com.codegym.task.task36.task3608.controller.Controller;
import com.codegym.task.task36.task3608.view.View;
import com.codegym.task.task36.task3608.view.UsersView;
import com.codegym.task.task36.task3608.dao.mock.DataSource;
import com.codegym.task.task36.task3608.model.Model;
import com.codegym.task.task36.task3608.model.DataModel;
import java.lang.NullPointerException;
public class Solution {
private UsersView usersView;
public void setUsersView(UsersView usersView){
this.usersView = usersView;
}
public static void main(String[] args) throws NullPointerException {
UsersView usersView = new UsersView();
usersView.fireShowAllUsersEvent();
}
}