lunarmodules / busted

Elegant Lua unit testing.
https://lunarmodules.github.io/busted/
MIT License
1.4k stars 185 forks source link

How to invoke OpenResty library from busted #616

Closed kg0r0 closed 4 years ago

kg0r0 commented 4 years ago

When testing code that includes OpenResty libraries with busted, the following error occurs:

attempt to index global 'ngx' (a nil value)

I saw the following issues, but it did not solve. https://github.com/Olivine-Labs/busted/issues/414

I'm sorry, can you tell me the detailed steps?

idevz commented 4 years ago

you can using this as kong dose https://github.com/Kong/kong/blob/master/bin/busted

kg0r0 commented 4 years ago

Thank you for your reply! I'll try it!