mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-19 08:35:05 +02:00
1 parent
b565f3e00a
commit
16c3216dc6
4 files changed
+60
-18
No files matched your search
@@ -0,0 +1,13 @@
|
||||
import {cutString} from './string.ts';
|
||||
|
||||
test('cutString', () => {
|
||||
let [before, after, ok] = cutString('a = b = c', '=');
|
||||
expect(before).toBe('a ');
|
||||
expect(after).toBe(' b = c');
|
||||
expect(ok).toBe(true);
|
||||
|
||||
[before, after, ok] = cutString(' a ', '=');
|
||||
expect(before).toBe(' a ');
|
||||
expect(after).toBe('');
|
||||
expect(ok).toBe(false);
|
||||
});
|
||||
Reference in new issue
Block a user