diff --git a/test/conftest.py b/test/conftest.py
index 0404cbe043b7adf2fe500c8ec9be23c974694dad..ecc9802e80211af95b5fc28223c9b59231eb54a7 100644
--- a/test/conftest.py
+++ b/test/conftest.py
@@ -15,18 +15,18 @@ def create_dir_rec_if_needed(dirname):
         os.makedirs(dirname)
 
 
-def run_script(delim,
-             threshold,
-             input_swf=KTH_WL.swf_file,
-             dyn_red=True,
-             graph=False):
-    if input_swf == KTH_WL.swf_file:
-        pfx = "KTH"
-    else:
-        pfx = input_swf.split("/")[-1].split(".")[0]
-    test_name = f"{pfx}_{delim}_t{threshold}"
-    if not dyn_red:
-        test_name += "_nodyn"
+def run_script(delim, threshold,
+              input_swf=KTH_WL.swf_file, test_name=None,
+              dyn_red=True, graph=False):
+    if test_name is None:
+        if input_swf == KTH_WL.swf_file:
+            pfx = "KTH"
+        else:
+            pfx = input_swf.split("/")[-1].split(".")[0]
+        test_name = f"{pfx}_{delim}_t{threshold}"
+        if not dyn_red:
+            test_name += "_nodyn"
+
     out_dir = os.path.abspath(f'test-out/{test_name}')
     create_dir_rec_if_needed(out_dir)
 
diff --git a/test/expected_output/load_platform.SABjson b/test/expected_output/load_platform.SABjson
index d035a6efd92e1fd14f163675a68b1bab2510807e..3cfb240d2021ed037a90f31ff08d2e1708e6c1a5 100644
--- a/test/expected_output/load_platform.SABjson
+++ b/test/expected_output/load_platform.SABjson
@@ -36,18 +36,25 @@
         },
         {
             "id": 3,
-            "first_submit_time": 10000.0,
+            "first_submit_time": 9000.0,
             "preceding_sessions": [
                 2
             ],
             "thinking_time_after_preceding_session": [
-                7000.0
+                6000.0
             ],
-            "nb_jobs": 1,
+            "nb_jobs": 2,
             "jobs": [
                 {
-                    "id": 3,
-                    "profile": "1000",
+                    "id": 5,
+                    "profile": "5000",
+                    "res": 16,
+                    "subtime": 0.0,
+                    "walltime": 2592000.0
+                },
+                {
+                    "id": 6,
+                    "profile": "5000",
                     "res": 16,
                     "subtime": 0.0,
                     "walltime": 2592000.0
@@ -56,17 +63,17 @@
         },
         {
             "id": 4,
-            "first_submit_time": 12000.0,
+            "first_submit_time": 10000.0,
             "preceding_sessions": [
-                3
+                2
             ],
             "thinking_time_after_preceding_session": [
-                1000.0
+                7000.0
             ],
             "nb_jobs": 1,
             "jobs": [
                 {
-                    "id": 4,
+                    "id": 3,
                     "profile": "1000",
                     "res": 16,
                     "subtime": 0.0,
@@ -76,25 +83,18 @@
         },
         {
             "id": 5,
-            "first_submit_time": 9000.0,
+            "first_submit_time": 12000.0,
             "preceding_sessions": [
-                2
+                4
             ],
             "thinking_time_after_preceding_session": [
-                6000.0
+                1000.0
             ],
-            "nb_jobs": 2,
+            "nb_jobs": 1,
             "jobs": [
                 {
-                    "id": 5,
-                    "profile": "5000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                },
-                {
-                    "id": 6,
-                    "profile": "5000",
+                    "id": 4,
+                    "profile": "1000",
                     "res": 16,
                     "subtime": 0.0,
                     "walltime": 2592000.0
diff --git a/test/expected_output/many_following.SABjson b/test/expected_output/many_following.SABjson
index 35a1e9cb7ca40e8093537045cabd847cca4760b2..f493068072e54bd124e3866a227ef3bb03f729bd 100644
--- a/test/expected_output/many_following.SABjson
+++ b/test/expected_output/many_following.SABjson
@@ -1,5 +1,5 @@
 {
-    "description": "A session (session 1) has five followers, four with a think time of 1000s and one with a think time of 2000s.",
+    "description": "A session (session 1) has five followers: four with a think time of 1000s, 1001s, 1002s and 1003s respectively (had to be changed compared to the batmen test) and one with a think time of 2000s.",
     "nb_res": 16,
     "sessions": [
         {
@@ -36,9 +36,9 @@
         },
         {
             "id": 3,
-            "first_submit_time": 2000.0,
+            "first_submit_time": 2001.0,
             "preceding_sessions": [1],
-            "thinking_time_after_preceding_session": [1000],
+            "thinking_time_after_preceding_session": [1001],
             "nb_jobs": 1,
             "jobs": [
                 {
@@ -52,9 +52,9 @@
         },
         {
             "id": 4,
-            "first_submit_time": 2000.0,
+            "first_submit_time": 2002.0,
             "preceding_sessions": [1],
-            "thinking_time_after_preceding_session": [1000],
+            "thinking_time_after_preceding_session": [1002],
             "nb_jobs": 1,
             "jobs": [
                 {
@@ -68,9 +68,9 @@
         },
         {
             "id": 5,
-            "first_submit_time": 2000.0,
+            "first_submit_time": 2003.0,
             "preceding_sessions": [1],
-            "thinking_time_after_preceding_session": [1000],
+            "thinking_time_after_preceding_session": [1003],
             "nb_jobs": 1,
             "jobs": [
                 {
diff --git a/test/expected_output/many_preceding.SABjson b/test/expected_output/many_preceding.SABjson
index 8ca4d285b1d0d329de8f29a161964b680387f053..6cde9573965a464930f7a3a14bdda14a3a92389e 100644
--- a/test/expected_output/many_preceding.SABjson
+++ b/test/expected_output/many_preceding.SABjson
@@ -1,5 +1,5 @@
 {
-    "description": "A session (session 6) depends on five others, with a think time of 1000s.",
+    "description": "A session (session 6) depends on five others, with a think time of 1000s. Slightly different than batmen version.",
     "nb_res": 16,
     "sessions": [
         {
@@ -20,14 +20,14 @@
         },
         {
             "id": 2,
-            "first_submit_time": 1000.0,
+            "first_submit_time": 1001.0,
             "preceding_sessions": [],
             "thinking_time_after_preceding_session": [],
             "nb_jobs": 1,
             "jobs": [
                 {
                     "id": 2,
-                    "profile": "2000",
+                    "profile": "1500",
                     "res": 16,
                     "subtime": 0.0,
                     "walltime": 2592000.0
@@ -36,7 +36,7 @@
         },
         {
             "id": 3,
-            "first_submit_time": 1000.0,
+            "first_submit_time": 1002.0,
             "preceding_sessions": [],
             "thinking_time_after_preceding_session": [],
             "nb_jobs": 1,
diff --git a/test/expected_output/many_start_sessions.SABjson b/test/expected_output/many_start_sessions.SABjson
deleted file mode 100644
index 2a48296e478ae4f08aa802e0c31aac4b998cc66b..0000000000000000000000000000000000000000
--- a/test/expected_output/many_start_sessions.SABjson
+++ /dev/null
@@ -1,86 +0,0 @@
-{
-    "description": "Five start sessions with no dependency between them.",
-    "nb_res": 16,
-    "sessions": [
-        {
-            "id": 1,
-            "first_submit_time": 1000.0,
-            "preceding_sessions": [],
-            "thinking_time_after_preceding_session": [],
-            "nb_jobs": 1,
-            "jobs": [
-                {
-                    "id": 1,
-                    "profile": "1000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                }
-            ]
-        },
-        {
-            "id": 2,
-            "first_submit_time": 1000.0,
-            "preceding_sessions": [],
-            "thinking_time_after_preceding_session": [],
-            "nb_jobs": 1,
-            "jobs": [
-                {
-                    "id": 2,
-                    "profile": "2000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                }
-            ]
-        },
-        {
-            "id": 3,
-            "first_submit_time": 1000.0,
-            "preceding_sessions": [],
-            "thinking_time_after_preceding_session": [],
-            "nb_jobs": 1,
-            "jobs": [
-                {
-                    "id": 3,
-                    "profile": "1000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                }
-            ]
-        },
-        {
-            "id": 4,
-            "first_submit_time": 1500.0,
-            "preceding_sessions": [],
-            "thinking_time_after_preceding_session": [],
-            "nb_jobs": 1,
-            "jobs": [
-                {
-                    "id": 4,
-                    "profile": "1000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                }
-            ]
-        },
-        {
-            "id": 5,
-            "first_submit_time": 2000.0,
-            "preceding_sessions": [],
-            "thinking_time_after_preceding_session": [],
-            "nb_jobs": 1,
-            "jobs": [
-                {
-                    "id": 5,
-                    "profile": "1000",
-                    "res": 16,
-                    "subtime": 0.0,
-                    "walltime": 2592000.0
-                }
-            ]
-        }
-    ]
-}
\ No newline at end of file
diff --git a/test/expected_output/zero_think_time.SABjson b/test/expected_output/zero_think_time.SABjson
index f88e3284c938ed000905eb5c7d7d356f49fa5115..278d842c339a2d2d38013a479b5ba24c6469d33b 100644
--- a/test/expected_output/zero_think_time.SABjson
+++ b/test/expected_output/zero_think_time.SABjson
@@ -20,7 +20,7 @@
         },
         {
             "id": 2,
-            "first_submit_time": 2000.0,
+            "first_submit_time": 1000.0,
             "preceding_sessions": [1],
             "thinking_time_after_preceding_session": [0],
             "nb_jobs": 1,
diff --git a/test/test_expected_outputs.py b/test/test_expected_outputs.py
index b15135e4079e44b18b96f9491cff3666e79dfe5b..1866c775cd23693f25ca659a9225d0d1e1eb4e0d 100644
--- a/test/test_expected_outputs.py
+++ b/test/test_expected_outputs.py
@@ -56,4 +56,18 @@ def test_example_workload():
 
     test_name = "example_last_t30"
     run_script(delim="last", threshold=30, input_swf="workloads/example.swf")
-    compare_with_expected_output(test_name)
\ No newline at end of file
+    compare_with_expected_output(test_name)
+
+def test_edge_cases():
+    """Hand written SWF and SABjson files, testing some edge cases.
+    Same tests than in batmen."""
+
+    test_name = "load_platform"
+    run_script(delim="arrival", threshold=10, 
+               input_swf=f"test/workload/{test_name}.swf", test_name=test_name)
+    compare_with_expected_output(test_name)
+
+    test_name = "many_following"
+    run_script(delim="arrival", threshold=0, 
+               input_swf=f"test/workload/{test_name}.swf", test_name=test_name)
+    compare_with_expected_output(test_name)
diff --git a/test/workload/load_platform.swf b/test/workload/load_platform.swf
new file mode 100644
index 0000000000000000000000000000000000000000..dd1ebc413103782b21b71f174c9184682c95e297
--- /dev/null
+++ b/test/workload/load_platform.swf
@@ -0,0 +1,9 @@
+; Written by hand.
+; Expected to produce load_platform.SABjson with arrival_t10
+
+    1        0      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    2     2000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    5     9000      0   5000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    6     9000      0   5000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    3    10000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    4    12000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
diff --git a/test/workload/many_following.swf b/test/workload/many_following.swf
new file mode 100644
index 0000000000000000000000000000000000000000..01ea036504b2f066a2480f85952d209437552972
--- /dev/null
+++ b/test/workload/many_following.swf
@@ -0,0 +1,9 @@
+; Written by hand.
+; Expected to produce many_following.SABjson with arrival_t0
+
+    1        0      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    2     2000      0   2000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    3     2001      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    4     2002      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    5     2003      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    6     3000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
diff --git a/test/workload/many_preceding.swf b/test/workload/many_preceding.swf
new file mode 100644
index 0000000000000000000000000000000000000000..107c63f297ecd0e3e12e524e1689b10223d212a8
--- /dev/null
+++ b/test/workload/many_preceding.swf
@@ -0,0 +1,9 @@
+; Written by hand.
+; Expected to produce many_preceding.SABjson with arrival_t0
+
+    1     1000   1000   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    2     1001    499   1500   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    3     1002    998   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    4     1500    500   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    5     2000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    6     4000      0   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
diff --git a/test/workload/no_session.swf b/test/workload/no_session.swf
new file mode 100644
index 0000000000000000000000000000000000000000..5ccaf6a20b9a8bd09d50005e0698fd8ecff8e3f8
--- /dev/null
+++ b/test/workload/no_session.swf
@@ -0,0 +1,4 @@
+; Written by hand.
+; Expected to produce no_session.SABjson, whatever the delimitation approach
+
+
diff --git a/test/workload/one_session_many_jobs.swf b/test/workload/one_session_many_jobs.swf
new file mode 100644
index 0000000000000000000000000000000000000000..c1a26cea9e845ddcaaed4c106c255c721277895e
--- /dev/null
+++ b/test/workload/one_session_many_jobs.swf
@@ -0,0 +1,13 @@
+; Written by hand.
+; Expected to produce one_session_many_jobs.SABjson with last_t10
+
+  750        0      0    450   16     -1    -1   16  86400      -1  1  1  1  -1 -1 -1 -1 -1
+  751      591      0    210   16     -1    -1   16  86400      -1  1  1  1  -1 -1 -1 -1 -1
+  752      767      0  81540   16     -1    -1   16  163068     -1  1  1  1  -1 -1 -1 -1 -1
+  757      895      0  86140   16     -1    -1   16  172260     -1  1  1  1  -1 -1 -1 -1 -1
+  758      959      0  86130   16     -1    -1   16  172250     -1  1  1  1  -1 -1 -1 -1 -1
+  768     1537      0    920   16     -1    -1   16  86400      -1  1  1  1  -1 -1 -1 -1 -1
+  781     1841      0    290   16     -1    -1   16  86400      -1  1  1  1  -1 -1 -1 -1 -1
+  791     2068      0  86130   16     -1    -1   16  172248     -1  1  1  1  -1 -1 -1 -1 -1
+  794     2149      0  86120   16     -1    -1   16  172226     -1  1  1  1  -1 -1 -1 -1 -1
+  795     2533      0  86130   16     -1    -1   16  172246     -1  1  1  1  -1 -1 -1 -1 -1
diff --git a/test/workload/zero_think_time.swf b/test/workload/zero_think_time.swf
new file mode 100644
index 0000000000000000000000000000000000000000..230bef070f364684ac47f6d2dbbb8762b339098b
--- /dev/null
+++ b/test/workload/zero_think_time.swf
@@ -0,0 +1,6 @@
+; Written by hand.
+; Expected to produce many_preceding.SABjson with last_t0
+
+    1        0   1000   1000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+    2     2000      0   2000   16     -1    -1   16  2592000    -1  1  1  1  -1 -1 -1 -1 -1
+