diff options
author | Simon Knox <psimyn@gmail.com> | 2018-01-16 22:22:45 +1100 |
---|---|---|
committer | Simon Knox <psimyn@gmail.com> | 2018-01-16 22:22:45 +1100 |
commit | aaa239686cb1504c3b992fbcec7f27f2c20ec5dd (patch) | |
tree | 92a7c57e99fde3a6d6eaac1b0eca6f196db0a41d /spec/javascripts/boards | |
parent | 5abdcf1be9fec29d14c1d5e7a9cc0aef2edaeff9 (diff) | |
download | gitlab-ce-aaa239686cb1504c3b992fbcec7f27f2c20ec5dd.tar.gz |
fix board filter parsing - don't replace encoded + symbols with spaces
Diffstat (limited to 'spec/javascripts/boards')
-rw-r--r-- | spec/javascripts/boards/utils/query_data_spec.js | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/spec/javascripts/boards/utils/query_data_spec.js b/spec/javascripts/boards/utils/query_data_spec.js new file mode 100644 index 00000000000..a8866ac6af4 --- /dev/null +++ b/spec/javascripts/boards/utils/query_data_spec.js @@ -0,0 +1,21 @@ +import queryData from '~/boards/utils/query_data'; + +describe('queryData', () => { + it('parses path for label with trailing +', () => { + const path = 'label_name[]=label%2B'; + expect( + queryData(path, {}), + ).toEqual({ + label_name: ['label+'], + }); + }); + + it('parses path for milestone with trailing +', () => { + const path = 'milestone_title=A%2B'; + expect( + queryData(path, {}), + ).toEqual({ + milestone_title: 'A+', + }); + }); +}); |