[Enterprise Search] Trivial API fixes (#82552)

* Fix embarrassing typo

* Fix uncovered line
This commit is contained in:
Constance 2020-11-04 08:17:18 -08:00 committed by GitHub
parent 1d13937fed
commit c59ad36dc6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 2 deletions

View file

@ -207,7 +207,7 @@ describe('callEnterpriseSearchConfigAPI', () => {
callEnterpriseSearchConfigAPI(mockDependencies);
jest.advanceTimersByTime(150);
expect(mockDependencies.log.warn).toHaveBeenCalledWith(
'Enterprise Search access check took over 100ms. Please ensure your Enterprise Search server is respondingly normally and not adversely impacting Kibana load speeds.'
'Enterprise Search access check took over 100ms. Please ensure your Enterprise Search server is responding normally and not adversely impacting Kibana load speeds.'
);
// Timeout

View file

@ -38,7 +38,7 @@ export const callEnterpriseSearchConfigAPI = async ({
}: IParams): Promise<IReturn> => {
if (!config.host) return {};
const TIMEOUT_WARNING = `Enterprise Search access check took over ${config.accessCheckTimeoutWarning}ms. Please ensure your Enterprise Search server is respondingly normally and not adversely impacting Kibana load speeds.`;
const TIMEOUT_WARNING = `Enterprise Search access check took over ${config.accessCheckTimeoutWarning}ms. Please ensure your Enterprise Search server is responding normally and not adversely impacting Kibana load speeds.`;
const TIMEOUT_MESSAGE = `Exceeded ${config.accessCheckTimeout}ms timeout while checking ${config.host}. Please consider increasing your enterpriseSearch.accessCheckTimeout value so that users aren't prevented from accessing Enterprise Search plugins due to slow responses.`;
const CONNECTION_ERROR = 'Could not perform access check to Enterprise Search';

View file

@ -45,6 +45,7 @@ describe('log settings routes', () => {
});
it('creates a request to enterprise search', () => {
mockRouter.callRoute({});
expect(mockRequestHandler.createRequest).toHaveBeenCalledWith({
path: '/as/log_settings',
});