question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unit Tests Failing

See original GitHub issue

In a new clone of the project, most unit tests are failing. The two successful tests are:

  • Server/Init
  • Server/StatsGet

After some debugging I found the bug inside the InitClient() method of Facepunch.Steamworks.Interop.NativeInterface.

Inside of this method the calls to Valve.Interop.NativeEntrypoints.Extended.SteamAPI_GetHSteamUser() and Valve.Interop.NativeEntrypoints.Extended.SteamAPI_GetHSteamPipe() both return zero.

That triggers the if ( pipe == 0 ) return false; guard clause which prevents client initialization.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Selkcipcommented, Jan 13, 2017

I was having this issue today. Turns out I set Steam to always run as admin because it complains about needing it to install a service every time. When I run VS as admin most of the tests that were failing due to SteamAPI_Init pass. In this case Unity also needs to be run as admin.

0reactions
garrynewmancommented, Dec 1, 2016

Anyone else having these issues?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why are unit tests failing seen as bad?
A failing test is a problem that was caught by your tooling before it reached a user. It's an opportunity to fix a...
Read more >
How to write good unit tests: Write failing tests first
To write reliable unit tests, always start writing a failing test. And make sure it fails for the right reasons. Follow the Red,...
Read more >
How do you deal with failing unit tests? [closed]
Either way it's an indication that the process is broken somewhere. So, particularly given the time of year and unless you have month-...
Read more >
Fixing Tests in CI/CD: Why are Your Tests Failing?
Taking failing tests seriously is important. Tests are meant to help. Even so, most information about running tests is based on opinion.
Read more >
Why are unit tests failing seen as bad?
If the tests document your system's expected logical behaviors, then a failing test tells you that it's not operating as intended or understood....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found