Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions core/libs/tests/GuestPad.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,16 @@ static void CheckExtControllerInformation(int handle) {
for (const int invalid : {-9999, -100, -2, -1, 0, handle + 1, 9999}) {
Require(scePadGetExtControllerInformation(invalid, extended.data()) == PAD_ERROR_INVALID_HANDLE);
}
const int special = scePadOpen_nid_postfix(0x20000099, PAD_PORT_TYPE_SPECIAL, 0, nullptr);
Require(special > 0);
extended.fill(0x5a);
Require(scePadGetExtControllerInformation(special, extended.data()) == PAD_OK);
for (std::size_t i = 0; i < 0x2c; ++i) Require(extended[i] == 0);
for (std::size_t i = 0x2c; i < extended.size(); ++i) Require(extended[i] == 0x5a);
errno = 71;
Require(scePadGetExtControllerInformation(special, reinterpret_cast<void*>(0x10)) == PAD_ERROR_INVALID_ARG);
Require(errno == 71);
Require(scePadClose_nid_postfix(special) == PAD_OK);
}

static bool LightBarValid() {
Expand Down
Loading