functests: Fix some ui/*_spec tests

This commit is contained in:
ZyX
2017-04-09 03:23:16 +03:00
parent ddaa41dee4
commit 0ac2afdec7
4 changed files with 24 additions and 29 deletions

View File

@@ -1,10 +1,8 @@
local helpers = require('test.functional.helpers')(after_each)
local Screen = require('test.functional.ui.screen')
local Paths = require('test.config.paths')
local clear, feed, insert = helpers.clear, helpers.feed, helpers.insert
local command, request, neq = helpers.command, helpers.request, helpers.neq
local meths = helpers.meths
if helpers.pending_win32(pending) then return end
@@ -14,10 +12,7 @@ describe('Buffer highlighting', function()
before_each(function()
clear()
meths.set_var('source_path', Paths.test_source_path)
command('let $VIMRUNTIME=source_path . "/runtime"')
command('set runtimepath=$VIMRUNTIME')
command("syntax on")
command('syntax on')
screen = Screen.new(40, 8)
screen:attach()
screen:set_default_attr_ids({

View File

@@ -52,7 +52,7 @@ describe('quickfix selection highlight', function()
{1:~ }|
{1:~ }|
{1:~ }|
:cad |
|
]])
end)
@@ -69,7 +69,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
command('cnext')
@@ -84,7 +84,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:cnext |
|
]])
end)
@@ -103,7 +103,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
command('cnext')
@@ -118,7 +118,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:cnext |
|
]])
end)
@@ -139,7 +139,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
feed('j')
@@ -154,7 +154,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
end)
@@ -175,7 +175,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
feed('j')
@@ -190,7 +190,7 @@ describe('quickfix selection highlight', function()
|{3:5}| Line |
|| |
{4:[Quickfix List] }|
:copen |
|
]])
end)
end)

View File

@@ -44,7 +44,7 @@ describe('Signs', function()
{2: }{0:~ }|
{2: }{0:~ }|
{2: }{0:~ }|
:sign place 3 line=1 name=pietx buffer=1 |
|
]])
end)
end)

View File

@@ -52,7 +52,7 @@ describe('Screen', function()
^ |
{0:~ }|
{0:~ }|
:syn match dAmpersand '[&][&]' conceal cchar=∧ |
|
]])
end)
@@ -68,7 +68,7 @@ describe('Screen', function()
|
{0:~ }|
{0:~ }|
:syn match dAmpersand '[&][&]' conceal cchar=∧ |
|
]])
end)
@@ -84,7 +84,7 @@ describe('Screen', function()
|
{0:~ }|
{0:~ }|
:syn match dAmpersand '[&][&]' conceal cchar=∧ |
|
]])
end)
@@ -100,7 +100,7 @@ describe('Screen', function()
|
{0:~ }|
{0:~ }|
:syn match dAmpersand '[&][&]' conceal cchar=∧ |
|
]])
end)
@@ -116,7 +116,7 @@ describe('Screen', function()
^ |
{0:~ }|
{0:~ }|
:syn match dAmpersand '[&][&]' conceal cchar=∧ |
|
]])
end)
end) -- multiple
@@ -135,7 +135,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:syn keyword kLambda lambda conceal cchar=λ |
|
]])
end) -- Keyword
@@ -218,7 +218,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:syn region rText start='<r>' end='</r>' cchar=- |
|
]])
end)
@@ -237,7 +237,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:syn region iText start='<i>' end='</i>' cchar=* |
|
]])
command("syntax conceal on")
command("syn region iText start='<i>' end='</i>' cchar=*")
@@ -251,7 +251,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:syn region iText start='<i>' end='</i>' cchar=* |
|
]])
end)
end) -- a region of text (implicit concealing)
@@ -279,7 +279,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:let &conceallevel=0 |
|
]])
end)
@@ -295,7 +295,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:let &conceallevel=1 |
|
]])
end)
@@ -311,7 +311,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:let &conceallevel=2 |
|
]])
end)
@@ -327,7 +327,7 @@ describe('Screen', function()
{0:~ }|
{0:~ }|
{0:~ }|
:let &conceallevel=3 |
|
]])
end)
end) -- conceallevel