glauth / glauth

A lightweight LDAP server for development, home use, or CI
MIT License
2.33k stars 211 forks source link

fix: go test not checking otp within allowed basedn #403

Closed Fusion closed 4 months ago

Fusion commented 4 months ago

Thank you for making a pull request!

A few things to be aware of as you're working on your PR:

WIP Tag

Incomplete PRs are more than welcome - it can be useful to collaborate before implementation of an idea is complete. However, if your PR is not ready for merge, please add [WIP] to the end of the title (work-in-progress).

Tests

Before committing, you are encouraged to run the small but growing test suite. This is accomplished by make test. Additionally, if you are adding new functionality, consider adding tests covering your feature.

CI

Each push to a branch connected to a PR will be run through GLAuth's CI system. Please use these to your advantage. In particular, the Github Actions integration tests rely on the LDAP queries returning with a set result, so if your changes will change the output, CI will likely fail.

To update, run make fast && make updatetest && make test. This will delete the output snapshots provided and make new ones. You can then inspect the changes and commit them.

Similarly, check codeclimate and try to fix what you find there if it fails.

ghost commented 4 months ago
👇 Click on the image for a new way to code review #### [![Review these changes using an interactive CodeSee Map](https://s3.us-east-2.amazonaws.com/maps.codesee.io/images/github/glauth/glauth/403/b46340c5/a6ab02376876ae6f2d6107fb73f1e4a6434d3d6e.svg)](https://app.codesee.io/r/reviews?pr=403&src=https%3A%2F%2Fgithub.com%2Fglauth%2Fglauth) #### Legend CodeSee Map legend
sonarcloud[bot] commented 4 months ago

Quality Gate Failed Quality Gate failed

Failed conditions
B Maintainability Rating on New Code (required ≥ A)

See analysis details on SonarCloud

idea Catch issues before they fail your Quality Gate with our IDE extension SonarLint SonarLint