SFML/test/Window/Mouse.test.cpp

18 lines
554 B
C++
Raw Permalink Normal View History

2023-09-19 09:48:27 +08:00
#include <SFML/Window/Mouse.hpp>
#include <catch2/catch_test_macros.hpp>
#include <WindowUtil.hpp>
TEST_CASE("[Window] sf::Mouse", runDisplayTests())
{
SECTION("isButtonPressed()")
{
CHECK(!sf::Mouse::isButtonPressed(sf::Mouse::Button::Left));
CHECK(!sf::Mouse::isButtonPressed(sf::Mouse::Button::Right));
CHECK(!sf::Mouse::isButtonPressed(sf::Mouse::Button::Middle));
CHECK(!sf::Mouse::isButtonPressed(sf::Mouse::Button::Extra1));
CHECK(!sf::Mouse::isButtonPressed(sf::Mouse::Button::Extra2));
}
}