Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Vim syntax highlighting for Specta/Expecta
VimL
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
syntax
.gitignore
LICENSE
README.md

README.md

specta.vim

Syntax highlighting for the specta & expecta Objective-C test frameworks.

Installation

With Vundle

Add:

Bundle 'Keithbsmiley/specta.vim'

To your .vimrc and run BundleInstall from within vim or vim +BundleInstall +qall from the command line

With Pathogen

cd ~/.vim/bundle
git clone https://github.com/Keithbsmiley/specta.vim.git

Setup

You can set the syntax for a file manually with set syntax=specta I recommend you do this in your .vimrc detecting your typical test filename.

autocmd BufNewFile,BufRead *Test.m setlocal syntax=specta foldmethod=syntax

This changes the syntax to specta whenever a file named *Test.m is read or written (written sets the syntax correctly for newly created files) You may also have to set the default filetype to Objective-C. I use something like:

autocmd BufNewFile,BufRead *.h,*.m,*.pch setlocal filetype=objc

You can also install cocoa.vim which adds some Objective-C highlighting features (automatically used by specta.vim if it's accessible).

This plugin also provides mappings for vim-endwise.

Known issues

If you find any other issues or have any recommendations on how to solve these let me know via issues/pull requests

Something went wrong with that request. Please try again.