You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							14 lines
						
					
					
						
							664 B
						
					
					
				
			
		
		
	
	
							14 lines
						
					
					
						
							664 B
						
					
					
				var test = require('tape'); | 
						|
var parse = require('../').parse; | 
						|
 | 
						|
test('comment', function (t) { | 
						|
    t.same(parse('beep#boop'), [ 'beep', { comment: 'boop' } ]); | 
						|
    t.same(parse('beep #boop'), [ 'beep', { comment: 'boop' } ]); | 
						|
    t.same(parse('beep # boop'), [ 'beep', { comment: 'boop' } ]); | 
						|
    t.same(parse('beep # > boop'), [ 'beep', { comment: '> boop' } ]); | 
						|
    t.same(parse('beep # "> boop"'), [ 'beep', { comment: '"> boop"' } ]); | 
						|
    t.same(parse('beep "#"'), [ 'beep', '#' ]); | 
						|
    t.same(parse('beep #"#"#'), [ 'beep', { comment: '"#"#' } ]); | 
						|
    t.same(parse('beep > boop # > foo'), [ 'beep', {op: '>'}, 'boop', { comment: '> foo' } ]); | 
						|
    t.end(); | 
						|
});
 | 
						|
 |