package app.controllers;

import com.google.common.eventbus.EventBus;

import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.mockito.InjectMocks;
import org.mockito.Mock;
import org.mockito.junit.jupiter.MockitoExtension;

import app.testing.FxTestTemplate;
import javafx.scene.control.MenuBar;
import javafx.scene.control.ToggleGroup;

// https://stackoverflow.com/questions/60403458/testing-overriden-eventhandler-in-java-javafx-spring-boot

@ExtendWith(MockitoExtension.class)
public class MenubarControllerTest extends FxTestTemplate {
  
  @Mock
  private MenuBar menubar;

  @Mock
  private ToggleGroup languageToggleGroup;

  private EventBus eventBus;

  @InjectMocks
  private MenubarController controller;


  @BeforeEach
  public void insertEventBus() {
    this.eventBus = new EventBus();
    this.controller.setEventBus(eventBus);
  }

  @Test
  @DisplayName("")
  public void testHandleOpenFile() {

  }

}
