mirror of
				https://gitlab.com/octtspacc/staticoso
				synced 2025-06-05 22:09:23 +02:00 
			
		
		
		
	First support for md extensions; Package all needed dependencies in the repo
This commit is contained in:
		
							
								
								
									
										17
									
								
								Source/node_modules/js-stringify/test/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								Source/node_modules/js-stringify/test/index.js
									
									
									
										generated
									
									
										vendored
									
									
										Normal file
									
								
							| @@ -0,0 +1,17 @@ | ||||
| 'use strict'; | ||||
|  | ||||
| var assert = require('assert'); | ||||
| var stringify = require('../'); | ||||
|  | ||||
| assert(stringify('foo') === '"foo"'); | ||||
| assert(stringify('foo\u2028bar\u2029baz') === '"foo\\u2028bar\\u2029baz"'); | ||||
| assert(stringify(new Date('2014-12-19T03:42:00.000Z')) === 'new Date("2014-12-19T03:42:00.000Z")'); | ||||
| assert(stringify({foo: 'bar'}) === '{"foo":"bar"}'); | ||||
| assert(stringify(undefined) === 'undefined'); | ||||
| assert(stringify(null) === 'null'); | ||||
| assert( | ||||
|   stringify({val: "</script><script>alert('bad actor')</script>"}) === | ||||
|   '{"val":"\\u003C\\u002Fscript\\u003E\\u003Cscript\\u003Ealert(\'bad actor\')\\u003C\\u002Fscript\\u003E"}' | ||||
| ); | ||||
|  | ||||
| console.log('tests passed'); | ||||
		Reference in New Issue
	
	Block a user