mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 22:30:04 +08:00
Add test for web html api
This commit is contained in:
parent
a761d83935
commit
dc987e3bcd
@ -182,7 +182,7 @@ function! s:template.toString() dict abort
|
||||
return xml
|
||||
endfunction
|
||||
|
||||
function! webapi#xml#createElement(name) abort
|
||||
function! s:self.createElement(name) abort
|
||||
let node = deepcopy(s:template)
|
||||
let node.name = a:name
|
||||
return node
|
||||
|
4
test/api/web/html.vader
Normal file
4
test/api/web/html.vader
Normal file
@ -0,0 +1,4 @@
|
||||
Execute (Test web#http api):
|
||||
let g:test_api_web_html = SpaceVim#api#import('web#html')
|
||||
let g:test_api_web_html_paser = g:test_api_web_html.parseURL('spacevim.org')
|
||||
AssertEqual g:test_api_web_html_paser.child[1].child[21].child[0], 'Home - SpaceVim'
|
Loading…
Reference in New Issue
Block a user