RiftLurker / open-screeps

:construction: reusable and tested building blocks for every screeps code base :construction:
MIT License
23 stars 4 forks source link

Test stubbing package. #28

Open Arcath opened 6 years ago

Arcath commented 6 years ago

I'm repeating myself in a few packages with my stubbings which isn't really necessary.

If we create @open-screeps\tests-stub it could provide:

It would then be usable by players to do testing in their own AI and us in open-screeps packages.

RiftLurker commented 6 years ago

I don't think a predefined selection of rooms and room objects (like creeps) is a good idea, as tests might want to check for different environments. Simple functions to create proper instances of them sounds like a good idea though. I'm going to give this another thought and come back with some ideas.