Re: Wisent grammar issues

Eric Ludlam <[email protected]> Sun, 13 Mar 2016 11:52:56 -0400
Newsgroups gmane.emacs.semantic
Message-ID <[email protected]>
On 03/12/2016 12:42 PM, Gracjan Polak wrote:
> Hi,
>
> As advised in other email on this list I try to wrap my grammar in a
> couple of ERT tests. I'm stuck trying to get wisent grammar do anything
> for me in context of ERT tests.


Sounds great that you are adding some tests!  The base parsing tests for 
CEDET (which are not very good and could use some help) are in:

tests/cedet/semantic/utest-parse.el

You could start with this structure, and if you are using TDD, build up 
a nicer set.  You will also see a large host of other tests nearby.  Any 
number of those structures could be helpful to you depending on what 
part of your development you are in.

I'm not really sure what might be wrong with your example code. It looks 
like has some of the right steps in it.  In the end, I think it would be 
easier to use the buffer-setup code that usually runs while editing to 
init things the same way.  Not as unit-test friendly, but likely 
sufficient.  Wisent and the tags have too many buffer dependencies.

Eric

------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140