diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-03-14 17:51:20 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-14 17:51:20 +0800 |
commit | ac8d71ff07a3354a27d6a5daab45d1e79e242269 (patch) | |
tree | bcf34685ce59b0ad89903ac769c4080dc1073349 /web_src/js/features/repo-findfile.test.js | |
parent | d56bb7420184c0c2f451f4bcaa96c9b3b00c393d (diff) | |
download | gitea-ac8d71ff07a3354a27d6a5daab45d1e79e242269.tar.gz gitea-ac8d71ff07a3354a27d6a5daab45d1e79e242269.zip |
Refactor branch/tag selector to Vue SFC (#23421)
Follow #23394
There were many bad smells in old code. This PR only moves the code into
Vue SFC, doesn't touch the unrelated logic.
update: after
https://github.com/go-gitea/gitea/pull/23421/commits/5f23218c851e12132f538a404c946bbf6ff38e62
, there should be no usage of the vue-rumtime-compiler anymore
(hopefully), so I think this PR could close #19851
---------
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'web_src/js/features/repo-findfile.test.js')
-rw-r--r-- | web_src/js/features/repo-findfile.test.js | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/web_src/js/features/repo-findfile.test.js b/web_src/js/features/repo-findfile.test.js index 5032185396..a90b0bf0a2 100644 --- a/web_src/js/features/repo-findfile.test.js +++ b/web_src/js/features/repo-findfile.test.js @@ -1,5 +1,5 @@ import {describe, expect, test} from 'vitest'; -import {strSubMatch, calcMatchedWeight, filterRepoFilesWeighted, escapePath} from './repo-findfile.js'; +import {strSubMatch, calcMatchedWeight, filterRepoFilesWeighted} from './repo-findfile.js'; describe('Repo Find Files', () => { test('strSubMatch', () => { @@ -32,9 +32,4 @@ describe('Repo Find Files', () => { expect(res).toHaveLength(2); expect(res[0].matchResult).toEqual(['', 'word', '.txt']); }); - - test('escapePath', () => { - expect(escapePath('a/b/c')).toEqual('a/b/c'); - expect(escapePath('a/b/ c')).toEqual('a/b/%20c'); - }); }); |