.
This commit is contained in:
		
							
								
								
									
										23
									
								
								qwen/nodejs/node_modules/html-escaper/test/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								qwen/nodejs/node_modules/html-escaper/test/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,23 @@
 | 
			
		||||
delete Object.freeze;
 | 
			
		||||
 | 
			
		||||
var html = require('../cjs');
 | 
			
		||||
 | 
			
		||||
console.assert(
 | 
			
		||||
  html.escape('&<>\'"') === '&<>'"',
 | 
			
		||||
  'correct escape'
 | 
			
		||||
);
 | 
			
		||||
 | 
			
		||||
console.assert(
 | 
			
		||||
  html.escape('<>\'"&') === '<>'"&',
 | 
			
		||||
  'correct inverted escape'
 | 
			
		||||
);
 | 
			
		||||
 | 
			
		||||
console.assert(
 | 
			
		||||
  '&<>\'"' === html.unescape('&<>'"'),
 | 
			
		||||
  'correct unescape'
 | 
			
		||||
);
 | 
			
		||||
 | 
			
		||||
console.assert(
 | 
			
		||||
  '<>\'"&' === html.unescape('<>'"&'),
 | 
			
		||||
  'correct inverted unescape'
 | 
			
		||||
);
 | 
			
		||||
		Reference in New Issue
	
	Block a user