+
+ /**
+ * Change the password on an open shaarli
+ */
+ public function testPostNewPasswordOnOpenShaarli(): void
+ {
+ $this->container->conf = $this->createMock(ConfigManager::class);
+ $this->container->conf->method('get')->with('security.open_shaarli')->willReturn(true);
+
+ $request = $this->createMock(Request::class);
+ $response = new Response();
+
+ $this->expectException(OpenShaarliPasswordException::class);
+
+ $this->controller->change($request, $response);
+ }