Using TestBox with an integration test with Wirebox (Livewire)

Can one do a get() or post() to a wirebox wire?

var event =“livewire/messages/wire.updateProfileModal”, {name=“Pete”, lastName=“Nelson”}); for example.

Can that be done. It runs without error and the event.getResponse().getStatusCode() returns a 200, however none of the profile data was updated. This leads me to believe that nothing actually happened.

I assume that anything ran in the textbox virtual environment would actually update a database record?

Yes, it should be a full integration test, so everything should work as normal. Can you post your code so we can assist. Also is this using cbwire? @gcopley

@lmajano Yes, that is a CBWIRE endpoint.

We have a section in the CBWIRE docs on testing. Have you tried any of those yet @webguy?

Thanks for the guidance!

No, I was unaware that a testing section was present on the CBWIRE docs. I took a look just now. It appears that this would require a separate CFC in the integration directory that mirrors the sample one except that it would extend cbwire.models.BaseWireTest vs. coldbox.system.testing.BaseTestCase?

@webguy That’s correct. Please let me know if you run into any issues.