mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
fix(editor): Case-sensitive credential search in NodeCredentials component (#17564)
This commit is contained in:
@@ -232,6 +232,15 @@ describe('NodeCredentials', () => {
|
|||||||
|
|
||||||
expect(screen.queryByText('OpenAi account')).not.toBeInTheDocument();
|
expect(screen.queryByText('OpenAi account')).not.toBeInTheDocument();
|
||||||
expect(screen.queryByText('Test OpenAi account')).toBeInTheDocument();
|
expect(screen.queryByText('Test OpenAi account')).toBeInTheDocument();
|
||||||
|
|
||||||
|
await userEvent.keyboard('{Escape}');
|
||||||
|
|
||||||
|
await userEvent.click(credentialsSelect);
|
||||||
|
|
||||||
|
await userEvent.type(credentialSearch, 'Test');
|
||||||
|
|
||||||
|
expect(screen.queryByText('OpenAi account')).not.toBeInTheDocument();
|
||||||
|
expect(screen.queryByText('Test OpenAi account')).toBeInTheDocument();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should open the new credential modal when clicked', async () => {
|
it('should open the new credential modal when clicked', async () => {
|
||||||
|
|||||||
@@ -500,7 +500,7 @@ function setFilter(newFilter = '') {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function matches(needle: string, haystack: string) {
|
function matches(needle: string, haystack: string) {
|
||||||
return haystack.toLocaleLowerCase().includes(needle);
|
return haystack.toLocaleLowerCase().includes(needle.toLocaleLowerCase());
|
||||||
}
|
}
|
||||||
|
|
||||||
async function onClickCreateCredential(type: ICredentialType | INodeCredentialDescription) {
|
async function onClickCreateCredential(type: ICredentialType | INodeCredentialDescription) {
|
||||||
|
|||||||
Reference in New Issue
Block a user