diff --git a/ethutil/natspec/natspec.go b/ethutil/natspec/natspec.go index ebc2658dab6572248c1f09c10919feca6b05261c..793bf59ae3381487e6cb359589e957b4d5ec1c49 100644 --- a/ethutil/natspec/natspec.go +++ b/ethutil/natspec/natspec.go @@ -10,7 +10,7 @@ type NatSpec struct { } // TODO: should initialise with abi and userdoc jsons -func NewNATSpec() (self *NatSpec, err error) { +func New() (self *NatSpec, err error) { self = new(NatSpec) self.jsvm = otto.New() diff --git a/ethutil/natspec/natspec_test.go b/ethutil/natspec/natspec_test.go index 3c70a08400f8b71c4e48eecf8861c6d74dbf2f62..498f8d78eef56622f74b173d0262939170793e4c 100644 --- a/ethutil/natspec/natspec_test.go +++ b/ethutil/natspec/natspec_test.go @@ -38,7 +38,7 @@ func TestNotice(t *testing.T) { method := "multiply" - ns, err := NewNATSpec() + ns, err := New() if err != nil { t.Errorf("NewNATSpec error %v", err) } @@ -68,6 +68,7 @@ func TestNotice(t *testing.T) { } } + // https://github.com/ethereum/natspec.js/issues/1 // badDesc := "Will multiply `e` by 7 and return `a * 7`." // notice, err = ns.Notice(tx, abi, method, badDesc)