...

Source file src/github.com/dop251/goja/builtin_function_test.go

Documentation: github.com/dop251/goja

     1  package goja
     2  
     3  import (
     4  	"testing"
     5  )
     6  
     7  func TestHashbangInFunctionConstructor(t *testing.T) {
     8  	const SCRIPT = `
     9  	assert.throws(SyntaxError, function() {
    10  		new Function("#!")
    11  	});
    12  	`
    13  	testScriptWithTestLib(SCRIPT, _undefined, t)
    14  }
    15  

View as plain text