Closed ajhollid closed 1 week ago
This pull request introduces a new test suite for the SettingsModule
, specifically located in Server/tests/db/settingsModule.test.js
. It employs the sinon
library to stub the findOne
and findOneAndUpdate
methods of the AppSettings
model. The suite comprises tests for both getAppSettings
and updateAppSettings
, focusing on verifying correct functionality and error handling. Each test is designed to ensure isolation by resetting stubs after execution.
File | Change Summary |
---|---|
Server/tests/db/settingsModule.test.js | Added a new test suite for SettingsModule , including tests for getAppSettings and updateAppSettings with stubs for error handling. |
SettingsService
, which includes testing the loadSettings
method that is directly related to the getAppSettings
and updateAppSettings
functions tested in the main PR.getAppSettings
and updateAppSettings
functions in the main PR.Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
This PR adds tests for the settings module