# Running Randomtest from command line

**URL:** <https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978>\
**Category:** ChoiceScript Help\
**Created:** [July 13, 2018, 8:26am UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978 "2018-07-13T08:26:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![HarrisPS](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/harrisps/32/240120_2.png) [@HarrisPS](https://forum.choiceofgames.com/u/HarrisPS)\
**Post date:** [July 13, 2018, 8:26am UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978/1 "2018-07-13T08:26:10Z")

</div>

I have a problem running Randomtest from the command line on Windows 10. I’m using the most recent ChoiceScript build from github.

When I run Randomtest without specifying a number of playthroughs, it goes through once. But when I specify a number (by entering randomtest 1000, for example), it stops and displays the following error:

```
js: "randomtest.js", line 38: exception from uncaught JavaScript throw: Error: COuldn't parse argument 1: 1000

```

Running Randomtest in the browser works fine. Using the command line worked a while back on my computer, so I’m not sure what’s changed now - am I doing something wrong, or is this a bug?

---

<div class="post-metadata">

**Author:** ![dfabulich](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/dfabulich/32/198373_2.png) [@dfabulich](https://forum.choiceofgames.com/u/dfabulich)\
**Post date:** [July 13, 2018, 8:51am UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978/2 "2018-07-13T08:51:39Z")

</div>

What’s the exact command that you’re running?

---

<div class="post-metadata">

**Author:** ![HarrisPS](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/harrisps/32/240120_2.png) [@HarrisPS](https://forum.choiceofgames.com/u/HarrisPS)\
**Post date:** [July 13, 2018, 9:28am UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978/3 "2018-07-13T09:28:08Z")

</div>

I go to the game directory, then enter randomtest 1000 (or whatever number I’m after).

---

<div class="post-metadata">

**Author:** ![anon8836198](https://avatars.discourse-cdn.com/v4/letter/a/e68b1a/32.png) [@anon8836198](https://forum.choiceofgames.com/u/anon8836198)\
**Post date:** [July 13, 2018, 10:37am UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978/4 "2018-07-13T10:37:59Z")

</div>

The argument is missing. `randomtest num=1000`

---

<div class="post-metadata">

**Author:** ![HarrisPS](https://sea3.discourse-cdn.com/choiceofgames/user_avatar/forum.choiceofgames.com/harrisps/32/240120_2.png) [@HarrisPS](https://forum.choiceofgames.com/u/HarrisPS)\
**Post date:** [July 13, 2018, 2:33pm UTC](https://forum.choiceofgames.com/t/running-randomtest-from-command-line/40978/5 "2018-07-13T14:33:07Z")

</div>

That’s now working. Thank you!
