Set up testing for project?


I’ve created a crate to check if the current program is running with Administrator privileges (, and was wondering how I could go about setting up testing for this project. The crate makes calls to winapi, and I’m not sure if mocking those calls is possible. My error code could be tested, but DwordError is dependent on another winapi call to GetLastError(), so I’m not sure if I can have much test coverage at all.