Skip to content

Commit

Permalink
Still rejects absent start state despite start_states_no_enforce. fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
StoneCypher committed Mar 26, 2024
1 parent d6570a2 commit 2a1093e
Show file tree
Hide file tree
Showing 26 changed files with 164 additions and 121 deletions.
17 changes: 16 additions & 1 deletion CHANGELOG.long.md
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

1144 merges; 199 releases
1145 merges; 199 releases



Expand All @@ -18,6 +18,21 @@ Published tags:



 

 

## [Untagged] - 3/25/2024 6:24:49 PM

Commit [d6570a279f57cdac528644cac12598ef07b4ed3e](https://github.com/StoneCypher/jssm/commit/d6570a279f57cdac528644cac12598ef07b4ed3e)

Author: `John Haugeland <stonecypher@gmail.com>`

* Accepts outside start state list due to flag start_states_no_enforce. fixes StoneCypher/fsl#1289




&nbsp;

&nbsp;
Expand Down
32 changes: 16 additions & 16 deletions CHANGELOG.md
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

1144 merges; 199 releases; Changlogging the last 10 commits; Full changelog at [CHANGELOG.long.md](CHANGELOG.long.md)
1145 merges; 199 releases; Changlogging the last 10 commits; Full changelog at [CHANGELOG.long.md](CHANGELOG.long.md)



Expand All @@ -18,6 +18,21 @@ Published tags:



&nbsp;

&nbsp;

## [Untagged] - 3/25/2024 6:24:49 PM

Commit [d6570a279f57cdac528644cac12598ef07b4ed3e](https://github.com/StoneCypher/jssm/commit/d6570a279f57cdac528644cac12598ef07b4ed3e)

Author: `John Haugeland <stonecypher@gmail.com>`

* Accepts outside start state list due to flag start_states_no_enforce. fixes StoneCypher/fsl#1289




&nbsp;

&nbsp;
Expand Down Expand Up @@ -158,19 +173,4 @@ Author: `John Haugeland <stonecypher@gmail.com>`
Merges [f834994, 28efd03]

* Merge pull request #566 from StoneCypher/BundleEs6Export
* attempt to resolve cjs loader issue




&nbsp;

&nbsp;

## [Untagged] - 2/5/2024 2:30:02 PM

Commit [28efd039469d4c7e6605532a8405e66392e8ff57](https://github.com/StoneCypher/jssm/commit/28efd039469d4c7e6605532a8405e66392e8ff57)

Author: `John Haugeland <stonecypher@gmail.com>`

* attempt to resolve cjs loader issue
6 changes: 3 additions & 3 deletions README.md
Expand Up @@ -18,7 +18,7 @@ Please edit the file it's derived from, instead: `./src/md/readme_base.md`
* Generated for version 5.98.0 at 3/25/2024, 6:23:27 PM
* Generated for version 5.98.0 at 3/25/2024, 6:28:17 PM
-->
# jssm 5.98.0
Expand All @@ -29,9 +29,9 @@ share online. Easy to embed.

Readable, useful state machines as one-liner strings.

***5,068 tests***, run 5,959 times.
***5,069 tests***, run 5,960 times.

* 5,059 specs with 100.0% coverage.
* 5,060 specs with 100.0% coverage.
* 9 fuzz tests with 12.4% coverage.

With 2,970 lines, that's about 1.7 tests per line, or 2.0 generated tests per line.
Expand Down
6 changes: 3 additions & 3 deletions dist/deno/README.md
Expand Up @@ -18,7 +18,7 @@ Please edit the file it's derived from, instead: `./src/md/readme_base.md`
* Generated for version 5.98.0 at 3/25/2024, 6:23:27 PM
* Generated for version 5.98.0 at 3/25/2024, 6:28:17 PM
-->
# jssm 5.98.0
Expand All @@ -29,9 +29,9 @@ share online. Easy to embed.

Readable, useful state machines as one-liner strings.

***5,068 tests***, run 5,959 times.
***5,069 tests***, run 5,960 times.

* 5,059 specs with 100.0% coverage.
* 5,060 specs with 100.0% coverage.
* 9 fuzz tests with 12.4% coverage.

With 2,970 lines, that's about 1.7 tests per line, or 2.0 generated tests per line.
Expand Down
2 changes: 1 addition & 1 deletion dist/deno/jssm.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/es6/version.js
@@ -1,2 +1,2 @@
const version = "5.98.0", build_time = 1711416101525;
const version = "5.98.0", build_time = 1711416391047;
export { version, build_time };
2 changes: 1 addition & 1 deletion dist/jssm.es5.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/jssm.es5.iife.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/jssm.es5.iife.nonmin.cjs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/jssm.es5.nonmin.cjs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/jssm.es6.mjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/jssm.es6.nonmin.cjs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

88 changes: 44 additions & 44 deletions docs/docs/classes/jssm.Machine.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/docs/classes/jssm_error.JssmError.html

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions docs/docs/modules/jssm.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/docs/modules/jssm_constants.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/docs/modules/jssm_types._internal_.html

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/docs/modules/jssm_types.html

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions docs/docs/modules/jssm_util.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/docs/modules/version.html

Large diffs are not rendered by default.

13 changes: 12 additions & 1 deletion docs/docs/pages/CHANGELOG.long.html
Expand Up @@ -3,14 +3,25 @@
<h1>Changelog</h1>
</a>
<p>All notable changes to this project will be documented in this file.</p>
<p>1144 merges; 199 releases</p>
<p>1145 merges; 199 releases</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>Published tags:</p>
<p><a href="#5__97__1">5.97.1</a>, <a href="#5__97__0">5.97.0</a>, <a href="#5__96__1">5.96.1</a>, <a href="#5__96__0">5.96.0</a>, <a href="#5__95__0">5.95.0</a>, <a href="#5__94__0">5.94.0</a>, <a href="#5__93__0">5.93.0</a>, <a href="#5__91__1">5.91.1</a>, <a href="#5__91__0">5.91.0</a>, <a href="#5__90__1">5.90.1</a>, <a href="#5__90__0">5.90.0</a>, <a href="#5__89__6">5.89.6</a>, <a href="#5__89__3">5.89.3</a>, <a href="#5__89__2">5.89.2</a>, <a href="#5__89__1">5.89.1</a>, <a href="#5__89__0">5.89.0</a>, <a href="#5__88__4">5.88.4</a>, <a href="#5__88__3">5.88.3</a>, <a href="#5__88__2">5.88.2</a>, <a href="#5__88__1">5.88.1</a>, <a href="#5__88__0">5.88.0</a>, <a href="#5__87__0">5.87.0</a>, <a href="#5__86__3">5.86.3</a>, <a href="#5__86__2">5.86.2</a>, <a href="#5__86__1">5.86.1</a>, <a href="#5__86__0">5.86.0</a>, <a href="#5__85__11">5.85.11</a>, <a href="#5__85__10">5.85.10</a>, <a href="#5__85__9">5.85.9</a>, <a href="#5__85__8">5.85.8</a>, <a href="#5__85__7">5.85.7</a>, <a href="#5__85__6">5.85.6</a>, <a href="#5__85__5">5.85.5</a>, <a href="#5__85__4">5.85.4</a>, <a href="#5__85__3">5.85.3</a>, <a href="#5__85__2">5.85.2</a>, <a href="#5__85__1">5.85.1</a>, <a href="#5__85__0">5.85.0</a>, <a href="#5__84__1">5.84.1</a>, <a href="#5__84__0">5.84.0</a>, <a href="#5__83__2">5.83.2</a>, <a href="#5__83__1">5.83.1</a>, <a href="#5__83__0">5.83.0</a>, <a href="#5__82__5">5.82.5</a>, <a href="#5__82__4">5.82.4</a>, <a href="#5__82__3">5.82.3</a>, <a href="#5__82__2">5.82.2</a>, <a href="#5__82__1">5.82.1</a>, <a href="#5__82__0">5.82.0</a>, <a href="#5__81__2">5.81.2</a>, <a href="#5__81__0">5.81.0</a>, <a href="#5__80__1">5.80.1</a>, <a href="#5__80__0">5.80.0</a>, <a href="#5__79__18">5.79.18</a>, <a href="#5__79__17">5.79.17</a>, <a href="#5__79__16">5.79.16</a>, <a href="#5__79__15">5.79.15</a>, <a href="#5__79__11">5.79.11</a>, <a href="#5__79__10">5.79.10</a>, <a href="#5__79__9">5.79.9</a>, <a href="#5__79__8">5.79.8</a>, <a href="#5__79__6">5.79.6</a>, <a href="#5__79__4">5.79.4</a>, <a href="#5__79__3">5.79.3</a>, <a href="#5__79__2">5.79.2</a>, <a href="#5__79__1">5.79.1</a>, <a href="#5__79__0">5.79.0</a>, <a href="#5__78__0">5.78.0</a>, <a href="#5__77__1">5.77.1</a>, <a href="#5__77__0">5.77.0</a>, <a href="#5__76__2">5.76.2</a>, <a href="#5__76__0">5.76.0</a>, <a href="#5__75__1">5.75.1</a>, <a href="#5__75__0">5.75.0</a>, <a href="#5__74__0">5.74.0</a>, <a href="#5__73__1">5.73.1</a>, <a href="#5__73__0">5.73.0</a>, <a href="#5__72__5">5.72.5</a>, <a href="#5__72__4">5.72.4</a>, <a href="#5__72__3">5.72.3</a>, <a href="#5__72__2">5.72.2</a>, <a href="#5__72__1">5.72.1</a>, <a href="#5__72__0">5.72.0</a>, <a href="#5__71__1">5.71.1</a>, <a href="#5__71__0">5.71.0</a>, <a href="#5__70__36">5.70.36</a>, <a href="#5__70__35">5.70.35</a>, <a href="#5__70__34">5.70.34</a>, <a href="#5__70__33">5.70.33</a>, <a href="#5__70__32">5.70.32</a>, <a href="#5__70__31">5.70.31</a>, <a href="#5__70__30">5.70.30</a>, <a href="#5__70__29">5.70.29</a>, <a href="#5__70__28">5.70.28</a>, <a href="#5__70__27">5.70.27</a>, <a href="#5__70__26">5.70.26</a>, <a href="#5__70__25">5.70.25</a>, <a href="#5__70__24">5.70.24</a>, <a href="#5__70__23">5.70.23</a>, <a href="#5__70__22">5.70.22</a>, <a href="#5__70__21">5.70.21</a>, <a href="#5__70__20">5.70.20</a>, <a href="#5__70__19">5.70.19</a>, <a href="#5__70__18">5.70.18</a>, <a href="#5__70__16">5.70.16</a>, <a href="#5__70__15">5.70.15</a>, <a href="#5__70__14">5.70.14</a>, <a href="#5__70__13">5.70.13</a>, <a href="#5__70__12">5.70.12</a>, <a href="#5__70__11">5.70.11</a>, <a href="#5__70__10">5.70.10</a>, <a href="#5__70__9">5.70.9</a>, <a href="#5__70__8">5.70.8</a>, <a href="#5__70__7">5.70.7</a>, <a href="#5__70__6">5.70.6</a>, <a href="#5__70__5">5.70.5</a>, <a href="#5__70__4">5.70.4</a>, <a href="#5__70__3">5.70.3</a>, <a href="#5__70__2">5.70.2</a>, <a href="#5__70__1">5.70.1</a>, <a href="#5__70__0">5.70.0</a>, <a href="#5__69__4">5.69.4</a>, <a href="#5__69__3">5.69.3</a>, <a href="#5__69__2">5.69.2</a>, <a href="#5__69__0">5.69.0</a>, <a href="#5__68__0">5.68.0</a>, <a href="#5__67__2">5.67.2</a>, <a href="#5__67__0">5.67.0</a>, <a href="#5__66__0">5.66.0</a>, <a href="#5__65__14">5.65.14</a>, <a href="#5__65__12">5.65.12</a>, <a href="#5__65__11">5.65.11</a>, <a href="#5__65__10">5.65.10</a>, <a href="#5__65__9">5.65.9</a>, <a href="#5__65__8">5.65.8</a>, <a href="#5__65__7">5.65.7</a>, <a href="#5__65__5">5.65.5</a>, <a href="#5__65__4">5.65.4</a>, <a href="#5__65__3">5.65.3</a>, <a href="#5__65__2">5.65.2</a>, <a href="#5__65__1">5.65.1</a>, <a href="#5__65__0">5.65.0</a>, <a href="#5__64__2">5.64.2</a>, <a href="#5__64__1">5.64.1</a>, <a href="#5__64__0">5.64.0</a>, <a href="#5__63__0">5.63.0</a>, <a href="#5__62__0">5.62.0</a>, <a href="#5__61__4">5.61.4</a>, <a href="#5__61__3">5.61.3</a>, <a href="#5__61__2">5.61.2</a>, <a href="#5__61__1">5.61.1</a>, <a href="#5__60__4">5.60.4</a>, <a href="#5__60__3">5.60.3</a>, <a href="#5__60__0">5.60.0</a>, <a href="#5__59__1">5.59.1</a>, <a href="#5__59__0">5.59.0</a>, <a href="#5__58__1">5.58.1</a>, <a href="#5__58__0">5.58.0</a>, <a href="#5__57__1">5.57.1</a>, <a href="#5__57__0">5.57.0</a>, <a href="#5__56__2">5.56.2</a>, <a href="#5__56__1">5.56.1</a>, <a href="#5__55__0">5.55.0</a>, <a href="#5__54__0">5.54.0</a>, <a href="#5__53__0">5.53.0</a>, <a href="#5__52__0">5.52.0</a>, <a href="#5__51__0">5.51.0</a>, <a href="#5__50__0">5.50.0</a>, <a href="#5__49__0">5.49.0</a>, <a href="#5__48__0">5.48.0</a>, <a href="#5__47__0">5.47.0</a>, <a href="#5__46__0">5.46.0</a>, <a href="#5__45__2">5.45.2</a>, <a href="#5__45__0">5.45.0</a>, <a href="#5__44__0">5.44.0</a>, <a href="#5__43__2">5.43.2</a>, <a href="#v5__42__0">v5.42.0</a>, <a href="#5__42__0">5.42.0</a>, <a href="#v5__41__15">v5.41.15</a>, <a href="#5__41__15">5.41.15</a>, <a href="#v5__41__14">v5.41.14</a>, <a href="#5__41__14">5.41.14</a>, <a href="#v5__41__12">v5.41.12</a>, <a href="#5__41__12">5.41.12</a>, <a href="#v5__41__10">v5.41.10</a>, <a href="#5__41__10">5.41.10</a>, <a href="#v5__41__9">v5.41.9</a>, <a href="#5__41__9">5.41.9</a>, <a href="#v5__41__8">v5.41.8</a>, <a href="#5__41__8">5.41.8</a>, <a href="#v5__41__7">v5.41.7</a>, <a href="#v5__41__2">v5.41.2</a>, <a href="#v5__41__1">v5.41.1</a>, <a href="#v5__32__14">v5.32.14</a>, <a href="#5__14__0">5.14.0</a>, <a href="#5__12__0">5.12.0</a>, <a href="#5__11__12">5.11.12</a>, <a href="#5__11__1">5.11.1</a>, <a href="#5__11__0">5.11.0</a></p>
<p>&nbsp;</p>
<p>&nbsp;</p>

<a href="#untagged---3252024-62449-pm" id="untagged---3252024-62449-pm" style="color: inherit; text-decoration: none;">
<h2>[Untagged] - 3/25/2024 6:24:49 PM</h2>
</a>
<p>Commit <a href="https://github.com/StoneCypher/jssm/commit/d6570a279f57cdac528644cac12598ef07b4ed3e">d6570a279f57cdac528644cac12598ef07b4ed3e</a></p>
<p>Author: <code>John Haugeland &lt;stonecypher@gmail.com&gt;</code></p>
<ul>
<li>Accepts outside start state list due to flag start_states_no_enforce. fixes StoneCypher/fsl#1289</li>
</ul>
<p>&nbsp;</p>
<p>&nbsp;</p>

<a href="#untagged---3252024-61707-pm" id="untagged---3252024-61707-pm" style="color: inherit; text-decoration: none;">
<h2>[Untagged] - 3/25/2024 6:17:07 PM</h2>
</a>
Expand Down
17 changes: 16 additions & 1 deletion src/doc_md/CHANGELOG.long.md
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

1144 merges; 199 releases
1145 merges; 199 releases



Expand All @@ -18,6 +18,21 @@ Published tags:



&nbsp;

&nbsp;

## [Untagged] - 3/25/2024 6:24:49 PM

Commit [d6570a279f57cdac528644cac12598ef07b4ed3e](https://github.com/StoneCypher/jssm/commit/d6570a279f57cdac528644cac12598ef07b4ed3e)

Author: `John Haugeland <stonecypher@gmail.com>`

* Accepts outside start state list due to flag start_states_no_enforce. fixes StoneCypher/fsl#1289




&nbsp;

&nbsp;
Expand Down
32 changes: 16 additions & 16 deletions src/doc_md/CHANGELOG.md
Expand Up @@ -2,7 +2,7 @@

All notable changes to this project will be documented in this file.

1144 merges; 199 releases; Changlogging the last 10 commits; Full changelog at [CHANGELOG.long.md](CHANGELOG.long.md)
1145 merges; 199 releases; Changlogging the last 10 commits; Full changelog at [CHANGELOG.long.md](CHANGELOG.long.md)



Expand All @@ -18,6 +18,21 @@ Published tags:



&nbsp;

&nbsp;

## [Untagged] - 3/25/2024 6:24:49 PM

Commit [d6570a279f57cdac528644cac12598ef07b4ed3e](https://github.com/StoneCypher/jssm/commit/d6570a279f57cdac528644cac12598ef07b4ed3e)

Author: `John Haugeland <stonecypher@gmail.com>`

* Accepts outside start state list due to flag start_states_no_enforce. fixes StoneCypher/fsl#1289




&nbsp;

&nbsp;
Expand Down Expand Up @@ -158,19 +173,4 @@ Author: `John Haugeland <stonecypher@gmail.com>`
Merges [f834994, 28efd03]

* Merge pull request #566 from StoneCypher/BundleEs6Export
* attempt to resolve cjs loader issue




&nbsp;

&nbsp;

## [Untagged] - 2/5/2024 2:30:02 PM

Commit [28efd039469d4c7e6605532a8405e66392e8ff57](https://github.com/StoneCypher/jssm/commit/28efd039469d4c7e6605532a8405e66392e8ff57)

Author: `John Haugeland <stonecypher@gmail.com>`

* attempt to resolve cjs loader issue
2 changes: 1 addition & 1 deletion src/tools/jssm.es5.iife.nonmin.cjs
Expand Up @@ -20654,7 +20654,7 @@ var jssm = (function (exports) {
named_colors: named_colors$1
});

const version = "5.98.0", build_time = 1711416101525;
const version = "5.98.0", build_time = 1711416391047;

// whargarbl lots of these return arrays could/should be sets
const { shapes, gviz_shapes, named_colors } = constants;
Expand Down
6 changes: 4 additions & 2 deletions src/ts/tests/general.spec.ts
Expand Up @@ -669,17 +669,19 @@ describe('initializes with states', () => {
expect(() => jssm.from(`start_states: [Red Yellow Green]; Red => Green => Yellow => Red;`, { initial_state: 'Blue' }))
.toThrow());


test('fails because that state is not in start state list', () =>
expect(() => jssm.from(`start_states: [Red Yellow]; Red => Green => Yellow => Red;`, { initial_state: 'Green' }))
.toThrow());


test('accepts state not in start state list due to flag', () => {
const machine = jssm.from(`start_states: [Red Yellow]; Red => Green => Yellow => Red;`, { initial_state: 'Green', start_states_no_enforce: true });
expect(machine.state()).toBe('Green');
});

test('rejects absent state despite flag', () =>
expect(() => jssm.from(`start_states: [Red Yellow]; Red => Green => Yellow => Red;`, { initial_state: 'Blue', start_states_no_enforce: true }))
.toThrow());


});

Expand Down
2 changes: 1 addition & 1 deletion src/ts/version.ts
@@ -1,5 +1,5 @@

const version : string = "5.98.0",
build_time : number = 1711416101525;
build_time : number = 1711416391047;

export { version, build_time };

0 comments on commit 2a1093e

Please sign in to comment.