The joy of Randomtest sigh. Can someone remind me how randomtests "Seeds" work

So Episodes 1-4 of season two pass quicktest but are failing randomtest specifically at “Seed 436”

*****Seed 436

RANDOMTEST FAILED: Error: line 268: No selectable options

Now I know what the error is but trying to troubleshoot it I run randomtest as a single iteration for “Seed 436” but that passes

Word count: 43214
RANDOMTEST PASSED
Time: 0.994s

I’ve tried to test 435 and 437 and they also pass.

This is very odd, has anyone else encountered this?

EDIT: This occurs in a seed every so often but each time they will pass individually so I’ m a but confused now. I can create a choice which bypasses the issue but I don’t like have a “bug fix” choice in the game.

2 Likes

You’ve got a problem on line 268 (an empty choice selection) which only triggers on specific run throughs of the game (i.e. seeds). Fix the the bug on 268 and randomtest won’t fail.

I would guess you have choices which have *if conditions which are triggering on some playthroughs but not others, or it’s a loop and you have options being hidden on repeat.

2 Likes

Hi I know what the issue is and can fix it with another choice. The thing that is confusing me is the fact randomtest tells me it fails at “Seed ##” but if I run that particular seed by itself it passes the test.

Run also the prior and the next one, I think I had a similar issue some time

1 Like

I’ve done that too they still pass. Its really weird. Going to try again tomorrow I think.

did you clear your cache?

3 Likes

Thats one thing I haven’t done but I’m using the CSIDE so not sure if it would still affect it or not.

1 Like

yes

Awesome :slight_smile:

1 Like

I’ll give that a try tomorrow!

edit: Cleared the cache and its working now.

3 Likes

The other thing to keep in mind is the “try unused options” flag. If you want to reproduce a seed test, you need that flag to be off.

So, turn off unused options, and if it fails on seed 756, you could run 756 with full text and see the error.

6 Likes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

I’m having problems with this issue. I’m hitting a bug on Seed 13116, and because the game is so large, I can’t open the randomtest output file to look more precisely at the path being taken.

I’m not using CSIDE or the web version. I’m using the windows batch file, running 1000 seeds starting at 13000, and have tried with unused options on and off, and it keeps passing. But it does hit the bug when I run 15000 starting at 0. Anything I can do differently? I’m getting towards the end of my tether because the bugs are very obscure, but necessary to fix, and I just need to generate a smaller output file in order to get a proper look at what’s going on.

1 Like

It’s a long shot and maybe it won’t work cause it’s just a specific path that isn’t working, but you can try opening the game in vscode with the choicescript language to see if it brings up any error.

Btw, does it say what error it is about?

I remember having outputs with millions of lines back when I didn’t have another way to test my game.

You can also use this:

It has a feature that can help you reduce the text output, you can use it if you have an idea where the bug could be happening.

“Ability to turn on showing text for only parts of a randomtest run using *comment text off and *comment text on.”

Thank you so much - I’ll give it a go. I’ve managed to fix the particular problem I was having, but I’ll try using that VS Code ChoiceScript extension next time I’m in need of seeing the full text.

The bugs are related to very obscure paths where a PC could have switched certain variables on and off which need to be mutually exclusive so I’m using *bug to test whether them being not mutually exclusive ever happens. It’s taken up a few days’ work now, and has been a learning experience for the future to do it earlier rather than later in the writing process, but I’m now at over 15K passing so I’m making progress.

4 Likes