rubyjs 0.7.0 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- data/bin/rubyjs +1 -1
- data/rubyjs.gemspec +1 -1
- data/src/rubyjs/compiler.rb +41 -0
- data/test/browser.test.html +618 -328
- data/test/browser.test.js +2000 -1797
- data/test/test_hot_ruby.rb +146 -0
- data/test/test_insertion_sort.rb +25 -0
- data/test/test_range.rb +17 -0
- metadata +126 -124
data/test/browser.test.html
CHANGED
@@ -786,7 +786,7 @@
|
|
786
786
|
<pre id="out_76"></pre>
|
787
787
|
</td>
|
788
788
|
<td>
|
789
|
-
<pre id="exp_76">Test
|
789
|
+
<pre id="exp_76">Test insertion sort</pre>
|
790
790
|
</td>
|
791
791
|
</tr>
|
792
792
|
|
@@ -806,7 +806,7 @@
|
|
806
806
|
<pre id="out_78"></pre>
|
807
807
|
</td>
|
808
808
|
<td>
|
809
|
-
<pre id="exp_78">
|
809
|
+
<pre id="exp_78">Before insertion sort:</pre>
|
810
810
|
</td>
|
811
811
|
</tr>
|
812
812
|
|
@@ -816,7 +816,7 @@
|
|
816
816
|
<pre id="out_79"></pre>
|
817
817
|
</td>
|
818
818
|
<td>
|
819
|
-
<pre id="exp_79">
|
819
|
+
<pre id="exp_79">[3, 6, 2, 5, 3, 7, 1, 8]</pre>
|
820
820
|
</td>
|
821
821
|
</tr>
|
822
822
|
|
@@ -826,7 +826,7 @@
|
|
826
826
|
<pre id="out_80"></pre>
|
827
827
|
</td>
|
828
828
|
<td>
|
829
|
-
<pre id="exp_80">
|
829
|
+
<pre id="exp_80">After insertion sort:</pre>
|
830
830
|
</td>
|
831
831
|
</tr>
|
832
832
|
|
@@ -836,7 +836,7 @@
|
|
836
836
|
<pre id="out_81"></pre>
|
837
837
|
</td>
|
838
838
|
<td>
|
839
|
-
<pre id="exp_81"
|
839
|
+
<pre id="exp_81">[1, 2, 3, 3, 5, 6, 7, 8]</pre>
|
840
840
|
</td>
|
841
841
|
</tr>
|
842
842
|
|
@@ -846,7 +846,7 @@
|
|
846
846
|
<pre id="out_82"></pre>
|
847
847
|
</td>
|
848
848
|
<td>
|
849
|
-
<pre id="exp_82"
|
849
|
+
<pre id="exp_82">~~~~~~~~~~~~~~~~~~~~</pre>
|
850
850
|
</td>
|
851
851
|
</tr>
|
852
852
|
|
@@ -856,7 +856,7 @@
|
|
856
856
|
<pre id="out_83"></pre>
|
857
857
|
</td>
|
858
858
|
<td>
|
859
|
-
<pre id="exp_83"
|
859
|
+
<pre id="exp_83">Test lebewesen</pre>
|
860
860
|
</td>
|
861
861
|
</tr>
|
862
862
|
|
@@ -866,7 +866,7 @@
|
|
866
866
|
<pre id="out_84"></pre>
|
867
867
|
</td>
|
868
868
|
<td>
|
869
|
-
<pre id="exp_84"
|
869
|
+
<pre id="exp_84">~~~~~~~~~~~~~~~~~~~~</pre>
|
870
870
|
</td>
|
871
871
|
</tr>
|
872
872
|
|
@@ -876,7 +876,7 @@
|
|
876
876
|
<pre id="out_85"></pre>
|
877
877
|
</td>
|
878
878
|
<td>
|
879
|
-
<pre id="exp_85">
|
879
|
+
<pre id="exp_85">miau, ich bin Leni</pre>
|
880
880
|
</td>
|
881
881
|
</tr>
|
882
882
|
|
@@ -886,7 +886,7 @@
|
|
886
886
|
<pre id="out_86"></pre>
|
887
887
|
</td>
|
888
888
|
<td>
|
889
|
-
<pre id="exp_86"
|
889
|
+
<pre id="exp_86">wau wau</pre>
|
890
890
|
</td>
|
891
891
|
</tr>
|
892
892
|
|
@@ -896,7 +896,7 @@
|
|
896
896
|
<pre id="out_87"></pre>
|
897
897
|
</td>
|
898
898
|
<td>
|
899
|
-
<pre id="exp_87">
|
899
|
+
<pre id="exp_87">ich jage Leni</pre>
|
900
900
|
</td>
|
901
901
|
</tr>
|
902
902
|
|
@@ -916,7 +916,7 @@
|
|
916
916
|
<pre id="out_89"></pre>
|
917
917
|
</td>
|
918
918
|
<td>
|
919
|
-
<pre id="exp_89">
|
919
|
+
<pre id="exp_89">Test expr</pre>
|
920
920
|
</td>
|
921
921
|
</tr>
|
922
922
|
|
@@ -936,7 +936,7 @@
|
|
936
936
|
<pre id="out_91"></pre>
|
937
937
|
</td>
|
938
938
|
<td>
|
939
|
-
<pre id="exp_91">
|
939
|
+
<pre id="exp_91">1</pre>
|
940
940
|
</td>
|
941
941
|
</tr>
|
942
942
|
|
@@ -946,7 +946,7 @@
|
|
946
946
|
<pre id="out_92"></pre>
|
947
947
|
</td>
|
948
948
|
<td>
|
949
|
-
<pre id="exp_92"
|
949
|
+
<pre id="exp_92">true</pre>
|
950
950
|
</td>
|
951
951
|
</tr>
|
952
952
|
|
@@ -956,7 +956,7 @@
|
|
956
956
|
<pre id="out_93"></pre>
|
957
957
|
</td>
|
958
958
|
<td>
|
959
|
-
<pre id="exp_93"
|
959
|
+
<pre id="exp_93">~~~~~~~~~~~~~~~~~~~~</pre>
|
960
960
|
</td>
|
961
961
|
</tr>
|
962
962
|
|
@@ -966,7 +966,7 @@
|
|
966
966
|
<pre id="out_94"></pre>
|
967
967
|
</td>
|
968
968
|
<td>
|
969
|
-
<pre id="exp_94">
|
969
|
+
<pre id="exp_94">Test simple output</pre>
|
970
970
|
</td>
|
971
971
|
</tr>
|
972
972
|
|
@@ -976,7 +976,7 @@
|
|
976
976
|
<pre id="out_95"></pre>
|
977
977
|
</td>
|
978
978
|
<td>
|
979
|
-
<pre id="exp_95"
|
979
|
+
<pre id="exp_95">~~~~~~~~~~~~~~~~~~~~</pre>
|
980
980
|
</td>
|
981
981
|
</tr>
|
982
982
|
|
@@ -986,7 +986,7 @@
|
|
986
986
|
<pre id="out_96"></pre>
|
987
987
|
</td>
|
988
988
|
<td>
|
989
|
-
<pre id="exp_96">
|
989
|
+
<pre id="exp_96">Hello World from RubyJS</pre>
|
990
990
|
</td>
|
991
991
|
</tr>
|
992
992
|
|
@@ -996,7 +996,7 @@
|
|
996
996
|
<pre id="out_97"></pre>
|
997
997
|
</td>
|
998
998
|
<td>
|
999
|
-
<pre id="exp_97"
|
999
|
+
<pre id="exp_97">~~~~~~~~~~~~~~~~~~~~</pre>
|
1000
1000
|
</td>
|
1001
1001
|
</tr>
|
1002
1002
|
|
@@ -1006,7 +1006,7 @@
|
|
1006
1006
|
<pre id="out_98"></pre>
|
1007
1007
|
</td>
|
1008
1008
|
<td>
|
1009
|
-
<pre id="exp_98">
|
1009
|
+
<pre id="exp_98">Test if</pre>
|
1010
1010
|
</td>
|
1011
1011
|
</tr>
|
1012
1012
|
|
@@ -1016,7 +1016,7 @@
|
|
1016
1016
|
<pre id="out_99"></pre>
|
1017
1017
|
</td>
|
1018
1018
|
<td>
|
1019
|
-
<pre id="exp_99"
|
1019
|
+
<pre id="exp_99">~~~~~~~~~~~~~~~~~~~~</pre>
|
1020
1020
|
</td>
|
1021
1021
|
</tr>
|
1022
1022
|
|
@@ -1026,7 +1026,7 @@
|
|
1026
1026
|
<pre id="out_100"></pre>
|
1027
1027
|
</td>
|
1028
1028
|
<td>
|
1029
|
-
<pre id="exp_100">
|
1029
|
+
<pre id="exp_100">OK</pre>
|
1030
1030
|
</td>
|
1031
1031
|
</tr>
|
1032
1032
|
|
@@ -1036,7 +1036,7 @@
|
|
1036
1036
|
<pre id="out_101"></pre>
|
1037
1037
|
</td>
|
1038
1038
|
<td>
|
1039
|
-
<pre id="exp_101">
|
1039
|
+
<pre id="exp_101">OK</pre>
|
1040
1040
|
</td>
|
1041
1041
|
</tr>
|
1042
1042
|
|
@@ -1046,7 +1046,7 @@
|
|
1046
1046
|
<pre id="out_102"></pre>
|
1047
1047
|
</td>
|
1048
1048
|
<td>
|
1049
|
-
<pre id="exp_102">
|
1049
|
+
<pre id="exp_102">OK</pre>
|
1050
1050
|
</td>
|
1051
1051
|
</tr>
|
1052
1052
|
|
@@ -1056,7 +1056,7 @@
|
|
1056
1056
|
<pre id="out_103"></pre>
|
1057
1057
|
</td>
|
1058
1058
|
<td>
|
1059
|
-
<pre id="exp_103">
|
1059
|
+
<pre id="exp_103">OK</pre>
|
1060
1060
|
</td>
|
1061
1061
|
</tr>
|
1062
1062
|
|
@@ -1076,7 +1076,7 @@
|
|
1076
1076
|
<pre id="out_105"></pre>
|
1077
1077
|
</td>
|
1078
1078
|
<td>
|
1079
|
-
<pre id="exp_105"
|
1079
|
+
<pre id="exp_105">"a"</pre>
|
1080
1080
|
</td>
|
1081
1081
|
</tr>
|
1082
1082
|
|
@@ -1086,7 +1086,7 @@
|
|
1086
1086
|
<pre id="out_106"></pre>
|
1087
1087
|
</td>
|
1088
1088
|
<td>
|
1089
|
-
<pre id="exp_106">
|
1089
|
+
<pre id="exp_106">true</pre>
|
1090
1090
|
</td>
|
1091
1091
|
</tr>
|
1092
1092
|
|
@@ -1096,7 +1096,7 @@
|
|
1096
1096
|
<pre id="out_107"></pre>
|
1097
1097
|
</td>
|
1098
1098
|
<td>
|
1099
|
-
<pre id="exp_107"
|
1099
|
+
<pre id="exp_107">"b"</pre>
|
1100
1100
|
</td>
|
1101
1101
|
</tr>
|
1102
1102
|
|
@@ -1106,7 +1106,7 @@
|
|
1106
1106
|
<pre id="out_108"></pre>
|
1107
1107
|
</td>
|
1108
1108
|
<td>
|
1109
|
-
<pre id="exp_108">
|
1109
|
+
<pre id="exp_108">false</pre>
|
1110
1110
|
</td>
|
1111
1111
|
</tr>
|
1112
1112
|
|
@@ -1116,7 +1116,7 @@
|
|
1116
1116
|
<pre id="out_109"></pre>
|
1117
1117
|
</td>
|
1118
1118
|
<td>
|
1119
|
-
<pre id="exp_109">
|
1119
|
+
<pre id="exp_109">nil</pre>
|
1120
1120
|
</td>
|
1121
1121
|
</tr>
|
1122
1122
|
|
@@ -1126,7 +1126,7 @@
|
|
1126
1126
|
<pre id="out_110"></pre>
|
1127
1127
|
</td>
|
1128
1128
|
<td>
|
1129
|
-
<pre id="exp_110">
|
1129
|
+
<pre id="exp_110">"a"</pre>
|
1130
1130
|
</td>
|
1131
1131
|
</tr>
|
1132
1132
|
|
@@ -1136,7 +1136,7 @@
|
|
1136
1136
|
<pre id="out_111"></pre>
|
1137
1137
|
</td>
|
1138
1138
|
<td>
|
1139
|
-
<pre id="exp_111">
|
1139
|
+
<pre id="exp_111">"a"</pre>
|
1140
1140
|
</td>
|
1141
1141
|
</tr>
|
1142
1142
|
|
@@ -1146,7 +1146,7 @@
|
|
1146
1146
|
<pre id="out_112"></pre>
|
1147
1147
|
</td>
|
1148
1148
|
<td>
|
1149
|
-
<pre id="exp_112"
|
1149
|
+
<pre id="exp_112">~~~~~~~~~~~~~~~~~~~~</pre>
|
1150
1150
|
</td>
|
1151
1151
|
</tr>
|
1152
1152
|
|
@@ -1156,7 +1156,7 @@
|
|
1156
1156
|
<pre id="out_113"></pre>
|
1157
1157
|
</td>
|
1158
1158
|
<td>
|
1159
|
-
<pre id="exp_113">
|
1159
|
+
<pre id="exp_113">Test class</pre>
|
1160
1160
|
</td>
|
1161
1161
|
</tr>
|
1162
1162
|
|
@@ -1166,7 +1166,7 @@
|
|
1166
1166
|
<pre id="out_114"></pre>
|
1167
1167
|
</td>
|
1168
1168
|
<td>
|
1169
|
-
<pre id="exp_114"
|
1169
|
+
<pre id="exp_114">~~~~~~~~~~~~~~~~~~~~</pre>
|
1170
1170
|
</td>
|
1171
1171
|
</tr>
|
1172
1172
|
|
@@ -1186,7 +1186,7 @@
|
|
1186
1186
|
<pre id="out_116"></pre>
|
1187
1187
|
</td>
|
1188
1188
|
<td>
|
1189
|
-
<pre id="exp_116">
|
1189
|
+
<pre id="exp_116">false</pre>
|
1190
1190
|
</td>
|
1191
1191
|
</tr>
|
1192
1192
|
|
@@ -1196,7 +1196,7 @@
|
|
1196
1196
|
<pre id="out_117"></pre>
|
1197
1197
|
</td>
|
1198
1198
|
<td>
|
1199
|
-
<pre id="exp_117">
|
1199
|
+
<pre id="exp_117">false</pre>
|
1200
1200
|
</td>
|
1201
1201
|
</tr>
|
1202
1202
|
|
@@ -1206,7 +1206,7 @@
|
|
1206
1206
|
<pre id="out_118"></pre>
|
1207
1207
|
</td>
|
1208
1208
|
<td>
|
1209
|
-
<pre id="exp_118">
|
1209
|
+
<pre id="exp_118">false</pre>
|
1210
1210
|
</td>
|
1211
1211
|
</tr>
|
1212
1212
|
|
@@ -1216,7 +1216,7 @@
|
|
1216
1216
|
<pre id="out_119"></pre>
|
1217
1217
|
</td>
|
1218
1218
|
<td>
|
1219
|
-
<pre id="exp_119">
|
1219
|
+
<pre id="exp_119">false</pre>
|
1220
1220
|
</td>
|
1221
1221
|
</tr>
|
1222
1222
|
|
@@ -1236,7 +1236,7 @@
|
|
1236
1236
|
<pre id="out_121"></pre>
|
1237
1237
|
</td>
|
1238
1238
|
<td>
|
1239
|
-
<pre id="exp_121">
|
1239
|
+
<pre id="exp_121">false</pre>
|
1240
1240
|
</td>
|
1241
1241
|
</tr>
|
1242
1242
|
|
@@ -1246,7 +1246,7 @@
|
|
1246
1246
|
<pre id="out_122"></pre>
|
1247
1247
|
</td>
|
1248
1248
|
<td>
|
1249
|
-
<pre id="exp_122">
|
1249
|
+
<pre id="exp_122">true</pre>
|
1250
1250
|
</td>
|
1251
1251
|
</tr>
|
1252
1252
|
|
@@ -1276,7 +1276,7 @@
|
|
1276
1276
|
<pre id="out_125"></pre>
|
1277
1277
|
</td>
|
1278
1278
|
<td>
|
1279
|
-
<pre id="exp_125">
|
1279
|
+
<pre id="exp_125">true</pre>
|
1280
1280
|
</td>
|
1281
1281
|
</tr>
|
1282
1282
|
|
@@ -1286,7 +1286,7 @@
|
|
1286
1286
|
<pre id="out_126"></pre>
|
1287
1287
|
</td>
|
1288
1288
|
<td>
|
1289
|
-
<pre id="exp_126">
|
1289
|
+
<pre id="exp_126">true</pre>
|
1290
1290
|
</td>
|
1291
1291
|
</tr>
|
1292
1292
|
|
@@ -1296,7 +1296,7 @@
|
|
1296
1296
|
<pre id="out_127"></pre>
|
1297
1297
|
</td>
|
1298
1298
|
<td>
|
1299
|
-
<pre id="exp_127">
|
1299
|
+
<pre id="exp_127">true</pre>
|
1300
1300
|
</td>
|
1301
1301
|
</tr>
|
1302
1302
|
|
@@ -1316,7 +1316,7 @@
|
|
1316
1316
|
<pre id="out_129"></pre>
|
1317
1317
|
</td>
|
1318
1318
|
<td>
|
1319
|
-
<pre id="exp_129">
|
1319
|
+
<pre id="exp_129">false</pre>
|
1320
1320
|
</td>
|
1321
1321
|
</tr>
|
1322
1322
|
|
@@ -1326,7 +1326,7 @@
|
|
1326
1326
|
<pre id="out_130"></pre>
|
1327
1327
|
</td>
|
1328
1328
|
<td>
|
1329
|
-
<pre id="exp_130">
|
1329
|
+
<pre id="exp_130">true</pre>
|
1330
1330
|
</td>
|
1331
1331
|
</tr>
|
1332
1332
|
|
@@ -1336,7 +1336,7 @@
|
|
1336
1336
|
<pre id="out_131"></pre>
|
1337
1337
|
</td>
|
1338
1338
|
<td>
|
1339
|
-
<pre id="exp_131">
|
1339
|
+
<pre id="exp_131">true</pre>
|
1340
1340
|
</td>
|
1341
1341
|
</tr>
|
1342
1342
|
|
@@ -1346,7 +1346,7 @@
|
|
1346
1346
|
<pre id="out_132"></pre>
|
1347
1347
|
</td>
|
1348
1348
|
<td>
|
1349
|
-
<pre id="exp_132">
|
1349
|
+
<pre id="exp_132">false</pre>
|
1350
1350
|
</td>
|
1351
1351
|
</tr>
|
1352
1352
|
|
@@ -1356,7 +1356,7 @@
|
|
1356
1356
|
<pre id="out_133"></pre>
|
1357
1357
|
</td>
|
1358
1358
|
<td>
|
1359
|
-
<pre id="exp_133">
|
1359
|
+
<pre id="exp_133">"String"</pre>
|
1360
1360
|
</td>
|
1361
1361
|
</tr>
|
1362
1362
|
|
@@ -1366,7 +1366,7 @@
|
|
1366
1366
|
<pre id="out_134"></pre>
|
1367
1367
|
</td>
|
1368
1368
|
<td>
|
1369
|
-
<pre id="exp_134">
|
1369
|
+
<pre id="exp_134">"NilClass"</pre>
|
1370
1370
|
</td>
|
1371
1371
|
</tr>
|
1372
1372
|
|
@@ -1376,7 +1376,7 @@
|
|
1376
1376
|
<pre id="out_135"></pre>
|
1377
1377
|
</td>
|
1378
1378
|
<td>
|
1379
|
-
<pre id="exp_135">
|
1379
|
+
<pre id="exp_135">true</pre>
|
1380
1380
|
</td>
|
1381
1381
|
</tr>
|
1382
1382
|
|
@@ -1386,7 +1386,7 @@
|
|
1386
1386
|
<pre id="out_136"></pre>
|
1387
1387
|
</td>
|
1388
1388
|
<td>
|
1389
|
-
<pre id="exp_136">
|
1389
|
+
<pre id="exp_136">true</pre>
|
1390
1390
|
</td>
|
1391
1391
|
</tr>
|
1392
1392
|
|
@@ -1396,7 +1396,7 @@
|
|
1396
1396
|
<pre id="out_137"></pre>
|
1397
1397
|
</td>
|
1398
1398
|
<td>
|
1399
|
-
<pre id="exp_137">
|
1399
|
+
<pre id="exp_137">String</pre>
|
1400
1400
|
</td>
|
1401
1401
|
</tr>
|
1402
1402
|
|
@@ -1406,7 +1406,7 @@
|
|
1406
1406
|
<pre id="out_138"></pre>
|
1407
1407
|
</td>
|
1408
1408
|
<td>
|
1409
|
-
<pre id="exp_138">
|
1409
|
+
<pre id="exp_138">T_TestClass::A</pre>
|
1410
1410
|
</td>
|
1411
1411
|
</tr>
|
1412
1412
|
|
@@ -1416,7 +1416,7 @@
|
|
1416
1416
|
<pre id="out_139"></pre>
|
1417
1417
|
</td>
|
1418
1418
|
<td>
|
1419
|
-
<pre id="exp_139"
|
1419
|
+
<pre id="exp_139">T_TestClass::B</pre>
|
1420
1420
|
</td>
|
1421
1421
|
</tr>
|
1422
1422
|
|
@@ -1426,7 +1426,7 @@
|
|
1426
1426
|
<pre id="out_140"></pre>
|
1427
1427
|
</td>
|
1428
1428
|
<td>
|
1429
|
-
<pre id="exp_140">
|
1429
|
+
<pre id="exp_140">T_TestClass::C</pre>
|
1430
1430
|
</td>
|
1431
1431
|
</tr>
|
1432
1432
|
|
@@ -1436,7 +1436,7 @@
|
|
1436
1436
|
<pre id="out_141"></pre>
|
1437
1437
|
</td>
|
1438
1438
|
<td>
|
1439
|
-
<pre id="exp_141"
|
1439
|
+
<pre id="exp_141">T_TestClass::D</pre>
|
1440
1440
|
</td>
|
1441
1441
|
</tr>
|
1442
1442
|
|
@@ -1446,7 +1446,7 @@
|
|
1446
1446
|
<pre id="out_142"></pre>
|
1447
1447
|
</td>
|
1448
1448
|
<td>
|
1449
|
-
<pre id="exp_142">
|
1449
|
+
<pre id="exp_142">T_TestClass::X</pre>
|
1450
1450
|
</td>
|
1451
1451
|
</tr>
|
1452
1452
|
|
@@ -1456,7 +1456,7 @@
|
|
1456
1456
|
<pre id="out_143"></pre>
|
1457
1457
|
</td>
|
1458
1458
|
<td>
|
1459
|
-
<pre id="exp_143">
|
1459
|
+
<pre id="exp_143">"T_TestClass::X"</pre>
|
1460
1460
|
</td>
|
1461
1461
|
</tr>
|
1462
1462
|
|
@@ -1466,7 +1466,7 @@
|
|
1466
1466
|
<pre id="out_144"></pre>
|
1467
1467
|
</td>
|
1468
1468
|
<td>
|
1469
|
-
<pre id="exp_144">
|
1469
|
+
<pre id="exp_144">"T_TestClass::A"</pre>
|
1470
1470
|
</td>
|
1471
1471
|
</tr>
|
1472
1472
|
|
@@ -1476,7 +1476,7 @@
|
|
1476
1476
|
<pre id="out_145"></pre>
|
1477
1477
|
</td>
|
1478
1478
|
<td>
|
1479
|
-
<pre id="exp_145">
|
1479
|
+
<pre id="exp_145">"T_TestClass::B"</pre>
|
1480
1480
|
</td>
|
1481
1481
|
</tr>
|
1482
1482
|
|
@@ -1486,7 +1486,7 @@
|
|
1486
1486
|
<pre id="out_146"></pre>
|
1487
1487
|
</td>
|
1488
1488
|
<td>
|
1489
|
-
<pre id="exp_146"
|
1489
|
+
<pre id="exp_146">~~~~~~~~~~~~~~~~~~~~</pre>
|
1490
1490
|
</td>
|
1491
1491
|
</tr>
|
1492
1492
|
|
@@ -1496,7 +1496,7 @@
|
|
1496
1496
|
<pre id="out_147"></pre>
|
1497
1497
|
</td>
|
1498
1498
|
<td>
|
1499
|
-
<pre id="exp_147"
|
1499
|
+
<pre id="exp_147">Test case</pre>
|
1500
1500
|
</td>
|
1501
1501
|
</tr>
|
1502
1502
|
|
@@ -1506,7 +1506,7 @@
|
|
1506
1506
|
<pre id="out_148"></pre>
|
1507
1507
|
</td>
|
1508
1508
|
<td>
|
1509
|
-
<pre id="exp_148"
|
1509
|
+
<pre id="exp_148">~~~~~~~~~~~~~~~~~~~~</pre>
|
1510
1510
|
</td>
|
1511
1511
|
</tr>
|
1512
1512
|
|
@@ -1516,7 +1516,7 @@
|
|
1516
1516
|
<pre id="out_149"></pre>
|
1517
1517
|
</td>
|
1518
1518
|
<td>
|
1519
|
-
<pre id="exp_149"
|
1519
|
+
<pre id="exp_149">OKAY</pre>
|
1520
1520
|
</td>
|
1521
1521
|
</tr>
|
1522
1522
|
|
@@ -1526,7 +1526,7 @@
|
|
1526
1526
|
<pre id="out_150"></pre>
|
1527
1527
|
</td>
|
1528
1528
|
<td>
|
1529
|
-
<pre id="exp_150">
|
1529
|
+
<pre id="exp_150">true</pre>
|
1530
1530
|
</td>
|
1531
1531
|
</tr>
|
1532
1532
|
|
@@ -1536,7 +1536,7 @@
|
|
1536
1536
|
<pre id="out_151"></pre>
|
1537
1537
|
</td>
|
1538
1538
|
<td>
|
1539
|
-
<pre id="exp_151">
|
1539
|
+
<pre id="exp_151">true</pre>
|
1540
1540
|
</td>
|
1541
1541
|
</tr>
|
1542
1542
|
|
@@ -1546,7 +1546,7 @@
|
|
1546
1546
|
<pre id="out_152"></pre>
|
1547
1547
|
</td>
|
1548
1548
|
<td>
|
1549
|
-
<pre id="exp_152">
|
1549
|
+
<pre id="exp_152">OK</pre>
|
1550
1550
|
</td>
|
1551
1551
|
</tr>
|
1552
1552
|
|
@@ -1556,7 +1556,7 @@
|
|
1556
1556
|
<pre id="out_153"></pre>
|
1557
1557
|
</td>
|
1558
1558
|
<td>
|
1559
|
-
<pre id="exp_153">
|
1559
|
+
<pre id="exp_153">OKAY</pre>
|
1560
1560
|
</td>
|
1561
1561
|
</tr>
|
1562
1562
|
|
@@ -1566,7 +1566,7 @@
|
|
1566
1566
|
<pre id="out_154"></pre>
|
1567
1567
|
</td>
|
1568
1568
|
<td>
|
1569
|
-
<pre id="exp_154"
|
1569
|
+
<pre id="exp_154">~~~~~~~~~~~~~~~~~~~~</pre>
|
1570
1570
|
</td>
|
1571
1571
|
</tr>
|
1572
1572
|
|
@@ -1576,7 +1576,7 @@
|
|
1576
1576
|
<pre id="out_155"></pre>
|
1577
1577
|
</td>
|
1578
1578
|
<td>
|
1579
|
-
<pre id="exp_155">
|
1579
|
+
<pre id="exp_155">Test splat</pre>
|
1580
1580
|
</td>
|
1581
1581
|
</tr>
|
1582
1582
|
|
@@ -1586,7 +1586,7 @@
|
|
1586
1586
|
<pre id="out_156"></pre>
|
1587
1587
|
</td>
|
1588
1588
|
<td>
|
1589
|
-
<pre id="exp_156"
|
1589
|
+
<pre id="exp_156">~~~~~~~~~~~~~~~~~~~~</pre>
|
1590
1590
|
</td>
|
1591
1591
|
</tr>
|
1592
1592
|
|
@@ -1596,7 +1596,7 @@
|
|
1596
1596
|
<pre id="out_157"></pre>
|
1597
1597
|
</td>
|
1598
1598
|
<td>
|
1599
|
-
<pre id="exp_157">[
|
1599
|
+
<pre id="exp_157">[]</pre>
|
1600
1600
|
</td>
|
1601
1601
|
</tr>
|
1602
1602
|
|
@@ -1606,7 +1606,7 @@
|
|
1606
1606
|
<pre id="out_158"></pre>
|
1607
1607
|
</td>
|
1608
1608
|
<td>
|
1609
|
-
<pre id="exp_158">[
|
1609
|
+
<pre id="exp_158">[]</pre>
|
1610
1610
|
</td>
|
1611
1611
|
</tr>
|
1612
1612
|
|
@@ -1616,7 +1616,7 @@
|
|
1616
1616
|
<pre id="out_159"></pre>
|
1617
1617
|
</td>
|
1618
1618
|
<td>
|
1619
|
-
<pre id="exp_159"
|
1619
|
+
<pre id="exp_159">[1]</pre>
|
1620
1620
|
</td>
|
1621
1621
|
</tr>
|
1622
1622
|
|
@@ -1626,7 +1626,7 @@
|
|
1626
1626
|
<pre id="out_160"></pre>
|
1627
1627
|
</td>
|
1628
1628
|
<td>
|
1629
|
-
<pre id="exp_160">
|
1629
|
+
<pre id="exp_160">[1]</pre>
|
1630
1630
|
</td>
|
1631
1631
|
</tr>
|
1632
1632
|
|
@@ -1636,7 +1636,7 @@
|
|
1636
1636
|
<pre id="out_161"></pre>
|
1637
1637
|
</td>
|
1638
1638
|
<td>
|
1639
|
-
<pre id="exp_161"
|
1639
|
+
<pre id="exp_161">[1]</pre>
|
1640
1640
|
</td>
|
1641
1641
|
</tr>
|
1642
1642
|
|
@@ -1646,7 +1646,7 @@
|
|
1646
1646
|
<pre id="out_162"></pre>
|
1647
1647
|
</td>
|
1648
1648
|
<td>
|
1649
|
-
<pre id="exp_162">
|
1649
|
+
<pre id="exp_162">[1, 2]</pre>
|
1650
1650
|
</td>
|
1651
1651
|
</tr>
|
1652
1652
|
|
@@ -1656,7 +1656,7 @@
|
|
1656
1656
|
<pre id="out_163"></pre>
|
1657
1657
|
</td>
|
1658
1658
|
<td>
|
1659
|
-
<pre id="exp_163">
|
1659
|
+
<pre id="exp_163">[1, 2]</pre>
|
1660
1660
|
</td>
|
1661
1661
|
</tr>
|
1662
1662
|
|
@@ -1666,7 +1666,7 @@
|
|
1666
1666
|
<pre id="out_164"></pre>
|
1667
1667
|
</td>
|
1668
1668
|
<td>
|
1669
|
-
<pre id="exp_164">
|
1669
|
+
<pre id="exp_164">[1, 2]</pre>
|
1670
1670
|
</td>
|
1671
1671
|
</tr>
|
1672
1672
|
|
@@ -1676,7 +1676,7 @@
|
|
1676
1676
|
<pre id="out_165"></pre>
|
1677
1677
|
</td>
|
1678
1678
|
<td>
|
1679
|
-
<pre id="exp_165">
|
1679
|
+
<pre id="exp_165">[1, 1, 2]</pre>
|
1680
1680
|
</td>
|
1681
1681
|
</tr>
|
1682
1682
|
|
@@ -1686,7 +1686,7 @@
|
|
1686
1686
|
<pre id="out_166"></pre>
|
1687
1687
|
</td>
|
1688
1688
|
<td>
|
1689
|
-
<pre id="exp_166"
|
1689
|
+
<pre id="exp_166">~~~~~~~~~~~~~~~~~~~~</pre>
|
1690
1690
|
</td>
|
1691
1691
|
</tr>
|
1692
1692
|
|
@@ -1696,7 +1696,7 @@
|
|
1696
1696
|
<pre id="out_167"></pre>
|
1697
1697
|
</td>
|
1698
1698
|
<td>
|
1699
|
-
<pre id="exp_167">
|
1699
|
+
<pre id="exp_167">Test string</pre>
|
1700
1700
|
</td>
|
1701
1701
|
</tr>
|
1702
1702
|
|
@@ -1706,7 +1706,7 @@
|
|
1706
1706
|
<pre id="out_168"></pre>
|
1707
1707
|
</td>
|
1708
1708
|
<td>
|
1709
|
-
<pre id="exp_168"
|
1709
|
+
<pre id="exp_168">~~~~~~~~~~~~~~~~~~~~</pre>
|
1710
1710
|
</td>
|
1711
1711
|
</tr>
|
1712
1712
|
|
@@ -1716,7 +1716,7 @@
|
|
1716
1716
|
<pre id="out_169"></pre>
|
1717
1717
|
</td>
|
1718
1718
|
<td>
|
1719
|
-
<pre id="exp_169">
|
1719
|
+
<pre id="exp_169">"hello"</pre>
|
1720
1720
|
</td>
|
1721
1721
|
</tr>
|
1722
1722
|
|
@@ -1726,7 +1726,7 @@
|
|
1726
1726
|
<pre id="out_170"></pre>
|
1727
1727
|
</td>
|
1728
1728
|
<td>
|
1729
|
-
<pre id="exp_170">
|
1729
|
+
<pre id="exp_170">"hallo\b\t\n"</pre>
|
1730
1730
|
</td>
|
1731
1731
|
</tr>
|
1732
1732
|
|
@@ -1736,7 +1736,7 @@
|
|
1736
1736
|
<pre id="out_171"></pre>
|
1737
1737
|
</td>
|
1738
1738
|
<td>
|
1739
|
-
<pre id="exp_171">"
|
1739
|
+
<pre id="exp_171">"hallo\\leute"</pre>
|
1740
1740
|
</td>
|
1741
1741
|
</tr>
|
1742
1742
|
|
@@ -1746,7 +1746,7 @@
|
|
1746
1746
|
<pre id="out_172"></pre>
|
1747
1747
|
</td>
|
1748
1748
|
<td>
|
1749
|
-
<pre id="exp_172">"
|
1749
|
+
<pre id="exp_172">"\"super\""</pre>
|
1750
1750
|
</td>
|
1751
1751
|
</tr>
|
1752
1752
|
|
@@ -1756,7 +1756,7 @@
|
|
1756
1756
|
<pre id="out_173"></pre>
|
1757
1757
|
</td>
|
1758
1758
|
<td>
|
1759
|
-
<pre id="exp_173">
|
1759
|
+
<pre id="exp_173">1</pre>
|
1760
1760
|
</td>
|
1761
1761
|
</tr>
|
1762
1762
|
|
@@ -1766,7 +1766,7 @@
|
|
1766
1766
|
<pre id="out_174"></pre>
|
1767
1767
|
</td>
|
1768
1768
|
<td>
|
1769
|
-
<pre id="exp_174">
|
1769
|
+
<pre id="exp_174">3</pre>
|
1770
1770
|
</td>
|
1771
1771
|
</tr>
|
1772
1772
|
|
@@ -1776,7 +1776,7 @@
|
|
1776
1776
|
<pre id="out_175"></pre>
|
1777
1777
|
</td>
|
1778
1778
|
<td>
|
1779
|
-
<pre id="exp_175">
|
1779
|
+
<pre id="exp_175">nil</pre>
|
1780
1780
|
</td>
|
1781
1781
|
</tr>
|
1782
1782
|
|
@@ -1786,7 +1786,7 @@
|
|
1786
1786
|
<pre id="out_176"></pre>
|
1787
1787
|
</td>
|
1788
1788
|
<td>
|
1789
|
-
<pre id="exp_176">
|
1789
|
+
<pre id="exp_176">2</pre>
|
1790
1790
|
</td>
|
1791
1791
|
</tr>
|
1792
1792
|
|
@@ -1796,7 +1796,7 @@
|
|
1796
1796
|
<pre id="out_177"></pre>
|
1797
1797
|
</td>
|
1798
1798
|
<td>
|
1799
|
-
<pre id="exp_177">
|
1799
|
+
<pre id="exp_177">8</pre>
|
1800
1800
|
</td>
|
1801
1801
|
</tr>
|
1802
1802
|
|
@@ -1806,7 +1806,7 @@
|
|
1806
1806
|
<pre id="out_178"></pre>
|
1807
1807
|
</td>
|
1808
1808
|
<td>
|
1809
|
-
<pre id="exp_178">"
|
1809
|
+
<pre id="exp_178">"h"</pre>
|
1810
1810
|
</td>
|
1811
1811
|
</tr>
|
1812
1812
|
|
@@ -1816,7 +1816,7 @@
|
|
1816
1816
|
<pre id="out_179"></pre>
|
1817
1817
|
</td>
|
1818
1818
|
<td>
|
1819
|
-
<pre id="exp_179">"
|
1819
|
+
<pre id="exp_179">"ha"</pre>
|
1820
1820
|
</td>
|
1821
1821
|
</tr>
|
1822
1822
|
|
@@ -1826,7 +1826,7 @@
|
|
1826
1826
|
<pre id="out_180"></pre>
|
1827
1827
|
</td>
|
1828
1828
|
<td>
|
1829
|
-
<pre id="exp_180">"
|
1829
|
+
<pre id="exp_180">"hallo"</pre>
|
1830
1830
|
</td>
|
1831
1831
|
</tr>
|
1832
1832
|
|
@@ -1836,7 +1836,7 @@
|
|
1836
1836
|
<pre id="out_181"></pre>
|
1837
1837
|
</td>
|
1838
1838
|
<td>
|
1839
|
-
<pre id="exp_181">"
|
1839
|
+
<pre id="exp_181">"0000000010"</pre>
|
1840
1840
|
</td>
|
1841
1841
|
</tr>
|
1842
1842
|
|
@@ -1846,7 +1846,7 @@
|
|
1846
1846
|
<pre id="out_182"></pre>
|
1847
1847
|
</td>
|
1848
1848
|
<td>
|
1849
|
-
<pre id="exp_182">"
|
1849
|
+
<pre id="exp_182">"10"</pre>
|
1850
1850
|
</td>
|
1851
1851
|
</tr>
|
1852
1852
|
|
@@ -1856,7 +1856,7 @@
|
|
1856
1856
|
<pre id="out_183"></pre>
|
1857
1857
|
</td>
|
1858
1858
|
<td>
|
1859
|
-
<pre id="exp_183">"
|
1859
|
+
<pre id="exp_183">"()(x"</pre>
|
1860
1860
|
</td>
|
1861
1861
|
</tr>
|
1862
1862
|
|
@@ -1866,7 +1866,7 @@
|
|
1866
1866
|
<pre id="out_184"></pre>
|
1867
1867
|
</td>
|
1868
1868
|
<td>
|
1869
|
-
<pre id="exp_184">"
|
1869
|
+
<pre id="exp_184">"1000000000"</pre>
|
1870
1870
|
</td>
|
1871
1871
|
</tr>
|
1872
1872
|
|
@@ -1876,7 +1876,7 @@
|
|
1876
1876
|
<pre id="out_185"></pre>
|
1877
1877
|
</td>
|
1878
1878
|
<td>
|
1879
|
-
<pre id="exp_185">"
|
1879
|
+
<pre id="exp_185">"10"</pre>
|
1880
1880
|
</td>
|
1881
1881
|
</tr>
|
1882
1882
|
|
@@ -1886,7 +1886,7 @@
|
|
1886
1886
|
<pre id="out_186"></pre>
|
1887
1887
|
</td>
|
1888
1888
|
<td>
|
1889
|
-
<pre id="exp_186">"
|
1889
|
+
<pre id="exp_186">"x()("</pre>
|
1890
1890
|
</td>
|
1891
1891
|
</tr>
|
1892
1892
|
|
@@ -1896,7 +1896,7 @@
|
|
1896
1896
|
<pre id="out_187"></pre>
|
1897
1897
|
</td>
|
1898
1898
|
<td>
|
1899
|
-
<pre id="exp_187">"
|
1899
|
+
<pre id="exp_187">"abc 3 def"</pre>
|
1900
1900
|
</td>
|
1901
1901
|
</tr>
|
1902
1902
|
|
@@ -1906,7 +1906,7 @@
|
|
1906
1906
|
<pre id="out_188"></pre>
|
1907
1907
|
</td>
|
1908
1908
|
<td>
|
1909
|
-
<pre id="exp_188">"
|
1909
|
+
<pre id="exp_188">"\"hallo\",4.5"</pre>
|
1910
1910
|
</td>
|
1911
1911
|
</tr>
|
1912
1912
|
|
@@ -1916,7 +1916,7 @@
|
|
1916
1916
|
<pre id="out_189"></pre>
|
1917
1917
|
</td>
|
1918
1918
|
<td>
|
1919
|
-
<pre id="exp_189"
|
1919
|
+
<pre id="exp_189">"harro"</pre>
|
1920
1920
|
</td>
|
1921
1921
|
</tr>
|
1922
1922
|
|
@@ -1926,7 +1926,7 @@
|
|
1926
1926
|
<pre id="out_190"></pre>
|
1927
1927
|
</td>
|
1928
1928
|
<td>
|
1929
|
-
<pre id="exp_190">
|
1929
|
+
<pre id="exp_190">"harro"</pre>
|
1930
1930
|
</td>
|
1931
1931
|
</tr>
|
1932
1932
|
|
@@ -1936,7 +1936,7 @@
|
|
1936
1936
|
<pre id="out_191"></pre>
|
1937
1937
|
</td>
|
1938
1938
|
<td>
|
1939
|
-
<pre id="exp_191"
|
1939
|
+
<pre id="exp_191">"harro"</pre>
|
1940
1940
|
</td>
|
1941
1941
|
</tr>
|
1942
1942
|
|
@@ -1946,7 +1946,7 @@
|
|
1946
1946
|
<pre id="out_192"></pre>
|
1947
1947
|
</td>
|
1948
1948
|
<td>
|
1949
|
-
<pre id="exp_192">
|
1949
|
+
<pre id="exp_192">"hablah blaho"</pre>
|
1950
1950
|
</td>
|
1951
1951
|
</tr>
|
1952
1952
|
|
@@ -1956,7 +1956,7 @@
|
|
1956
1956
|
<pre id="out_193"></pre>
|
1957
1957
|
</td>
|
1958
1958
|
<td>
|
1959
|
-
<pre id="exp_193"
|
1959
|
+
<pre id="exp_193">"ll"</pre>
|
1960
1960
|
</td>
|
1961
1961
|
</tr>
|
1962
1962
|
|
@@ -1966,7 +1966,7 @@
|
|
1966
1966
|
<pre id="out_194"></pre>
|
1967
1967
|
</td>
|
1968
1968
|
<td>
|
1969
|
-
<pre id="exp_194">
|
1969
|
+
<pre id="exp_194">"ll"</pre>
|
1970
1970
|
</td>
|
1971
1971
|
</tr>
|
1972
1972
|
|
@@ -1976,7 +1976,7 @@
|
|
1976
1976
|
<pre id="out_195"></pre>
|
1977
1977
|
</td>
|
1978
1978
|
<td>
|
1979
|
-
<pre id="exp_195"
|
1979
|
+
<pre id="exp_195">"ll"</pre>
|
1980
1980
|
</td>
|
1981
1981
|
</tr>
|
1982
1982
|
|
@@ -1986,7 +1986,7 @@
|
|
1986
1986
|
<pre id="out_196"></pre>
|
1987
1987
|
</td>
|
1988
1988
|
<td>
|
1989
|
-
<pre id="exp_196"
|
1989
|
+
<pre id="exp_196">~~~~~~~~~~~~~~~~~~~~</pre>
|
1990
1990
|
</td>
|
1991
1991
|
</tr>
|
1992
1992
|
|
@@ -1996,7 +1996,7 @@
|
|
1996
1996
|
<pre id="out_197"></pre>
|
1997
1997
|
</td>
|
1998
1998
|
<td>
|
1999
|
-
<pre id="exp_197">
|
1999
|
+
<pre id="exp_197">Test inspect</pre>
|
2000
2000
|
</td>
|
2001
2001
|
</tr>
|
2002
2002
|
|
@@ -2006,7 +2006,7 @@
|
|
2006
2006
|
<pre id="out_198"></pre>
|
2007
2007
|
</td>
|
2008
2008
|
<td>
|
2009
|
-
<pre id="exp_198"
|
2009
|
+
<pre id="exp_198">~~~~~~~~~~~~~~~~~~~~</pre>
|
2010
2010
|
</td>
|
2011
2011
|
</tr>
|
2012
2012
|
|
@@ -2016,7 +2016,7 @@
|
|
2016
2016
|
<pre id="out_199"></pre>
|
2017
2017
|
</td>
|
2018
2018
|
<td>
|
2019
|
-
<pre id="exp_199">
|
2019
|
+
<pre id="exp_199">[{"Hello"=>"Rubyconf"}]</pre>
|
2020
2020
|
</td>
|
2021
2021
|
</tr>
|
2022
2022
|
|
@@ -2026,7 +2026,7 @@
|
|
2026
2026
|
<pre id="out_200"></pre>
|
2027
2027
|
</td>
|
2028
2028
|
<td>
|
2029
|
-
<pre id="exp_200"
|
2029
|
+
<pre id="exp_200">~~~~~~~~~~~~~~~~~~~~</pre>
|
2030
2030
|
</td>
|
2031
2031
|
</tr>
|
2032
2032
|
|
@@ -2036,7 +2036,7 @@
|
|
2036
2036
|
<pre id="out_201"></pre>
|
2037
2037
|
</td>
|
2038
2038
|
<td>
|
2039
|
-
<pre id="exp_201">
|
2039
|
+
<pre id="exp_201">Test regexp</pre>
|
2040
2040
|
</td>
|
2041
2041
|
</tr>
|
2042
2042
|
|
@@ -2046,7 +2046,7 @@
|
|
2046
2046
|
<pre id="out_202"></pre>
|
2047
2047
|
</td>
|
2048
2048
|
<td>
|
2049
|
-
<pre id="exp_202"
|
2049
|
+
<pre id="exp_202">~~~~~~~~~~~~~~~~~~~~</pre>
|
2050
2050
|
</td>
|
2051
2051
|
</tr>
|
2052
2052
|
|
@@ -2056,7 +2056,7 @@
|
|
2056
2056
|
<pre id="out_203"></pre>
|
2057
2057
|
</td>
|
2058
2058
|
<td>
|
2059
|
-
<pre id="exp_203">
|
2059
|
+
<pre id="exp_203">"okay"</pre>
|
2060
2060
|
</td>
|
2061
2061
|
</tr>
|
2062
2062
|
|
@@ -2066,7 +2066,7 @@
|
|
2066
2066
|
<pre id="out_204"></pre>
|
2067
2067
|
</td>
|
2068
2068
|
<td>
|
2069
|
-
<pre id="exp_204">
|
2069
|
+
<pre id="exp_204">2</pre>
|
2070
2070
|
</td>
|
2071
2071
|
</tr>
|
2072
2072
|
|
@@ -2076,7 +2076,7 @@
|
|
2076
2076
|
<pre id="out_205"></pre>
|
2077
2077
|
</td>
|
2078
2078
|
<td>
|
2079
|
-
<pre id="exp_205"
|
2079
|
+
<pre id="exp_205">"ll"</pre>
|
2080
2080
|
</td>
|
2081
2081
|
</tr>
|
2082
2082
|
|
@@ -2086,7 +2086,7 @@
|
|
2086
2086
|
<pre id="out_206"></pre>
|
2087
2087
|
</td>
|
2088
2088
|
<td>
|
2089
|
-
<pre id="exp_206">
|
2089
|
+
<pre id="exp_206">nil</pre>
|
2090
2090
|
</td>
|
2091
2091
|
</tr>
|
2092
2092
|
|
@@ -2096,7 +2096,7 @@
|
|
2096
2096
|
<pre id="out_207"></pre>
|
2097
2097
|
</td>
|
2098
2098
|
<td>
|
2099
|
-
<pre id="exp_207"
|
2099
|
+
<pre id="exp_207">nil</pre>
|
2100
2100
|
</td>
|
2101
2101
|
</tr>
|
2102
2102
|
|
@@ -2106,7 +2106,7 @@
|
|
2106
2106
|
<pre id="out_208"></pre>
|
2107
2107
|
</td>
|
2108
2108
|
<td>
|
2109
|
-
<pre id="exp_208">
|
2109
|
+
<pre id="exp_208">"ll"</pre>
|
2110
2110
|
</td>
|
2111
2111
|
</tr>
|
2112
2112
|
|
@@ -2116,7 +2116,7 @@
|
|
2116
2116
|
<pre id="out_209"></pre>
|
2117
2117
|
</td>
|
2118
2118
|
<td>
|
2119
|
-
<pre id="exp_209">
|
2119
|
+
<pre id="exp_209">"o"</pre>
|
2120
2120
|
</td>
|
2121
2121
|
</tr>
|
2122
2122
|
|
@@ -2126,7 +2126,7 @@
|
|
2126
2126
|
<pre id="out_210"></pre>
|
2127
2127
|
</td>
|
2128
2128
|
<td>
|
2129
|
-
<pre id="exp_210">
|
2129
|
+
<pre id="exp_210">nil</pre>
|
2130
2130
|
</td>
|
2131
2131
|
</tr>
|
2132
2132
|
|
@@ -2136,7 +2136,7 @@
|
|
2136
2136
|
<pre id="out_211"></pre>
|
2137
2137
|
</td>
|
2138
2138
|
<td>
|
2139
|
-
<pre id="exp_211">
|
2139
|
+
<pre id="exp_211">nil</pre>
|
2140
2140
|
</td>
|
2141
2141
|
</tr>
|
2142
2142
|
|
@@ -2146,7 +2146,7 @@
|
|
2146
2146
|
<pre id="out_212"></pre>
|
2147
2147
|
</td>
|
2148
2148
|
<td>
|
2149
|
-
<pre id="exp_212"
|
2149
|
+
<pre id="exp_212">~~~~~~~~~~~~~~~~~~~~</pre>
|
2150
2150
|
</td>
|
2151
2151
|
</tr>
|
2152
2152
|
|
@@ -2156,7 +2156,7 @@
|
|
2156
2156
|
<pre id="out_213"></pre>
|
2157
2157
|
</td>
|
2158
2158
|
<td>
|
2159
|
-
<pre id="exp_213">
|
2159
|
+
<pre id="exp_213">Test args</pre>
|
2160
2160
|
</td>
|
2161
2161
|
</tr>
|
2162
2162
|
|
@@ -2166,7 +2166,7 @@
|
|
2166
2166
|
<pre id="out_214"></pre>
|
2167
2167
|
</td>
|
2168
2168
|
<td>
|
2169
|
-
<pre id="exp_214"
|
2169
|
+
<pre id="exp_214">~~~~~~~~~~~~~~~~~~~~</pre>
|
2170
2170
|
</td>
|
2171
2171
|
</tr>
|
2172
2172
|
|
@@ -2176,7 +2176,7 @@
|
|
2176
2176
|
<pre id="out_215"></pre>
|
2177
2177
|
</td>
|
2178
2178
|
<td>
|
2179
|
-
<pre id="exp_215">
|
2179
|
+
<pre id="exp_215">0</pre>
|
2180
2180
|
</td>
|
2181
2181
|
</tr>
|
2182
2182
|
|
@@ -2186,7 +2186,7 @@
|
|
2186
2186
|
<pre id="out_216"></pre>
|
2187
2187
|
</td>
|
2188
2188
|
<td>
|
2189
|
-
<pre id="exp_216">
|
2189
|
+
<pre id="exp_216">1</pre>
|
2190
2190
|
</td>
|
2191
2191
|
</tr>
|
2192
2192
|
|
@@ -2196,7 +2196,7 @@
|
|
2196
2196
|
<pre id="out_217"></pre>
|
2197
2197
|
</td>
|
2198
2198
|
<td>
|
2199
|
-
<pre id="exp_217"
|
2199
|
+
<pre id="exp_217">"hallo"</pre>
|
2200
2200
|
</td>
|
2201
2201
|
</tr>
|
2202
2202
|
|
@@ -2206,7 +2206,7 @@
|
|
2206
2206
|
<pre id="out_218"></pre>
|
2207
2207
|
</td>
|
2208
2208
|
<td>
|
2209
|
-
<pre id="exp_218">
|
2209
|
+
<pre id="exp_218">[]</pre>
|
2210
2210
|
</td>
|
2211
2211
|
</tr>
|
2212
2212
|
|
@@ -2216,7 +2216,7 @@
|
|
2216
2216
|
<pre id="out_219"></pre>
|
2217
2217
|
</td>
|
2218
2218
|
<td>
|
2219
|
-
<pre id="exp_219"
|
2219
|
+
<pre id="exp_219">--</pre>
|
2220
2220
|
</td>
|
2221
2221
|
</tr>
|
2222
2222
|
|
@@ -2226,7 +2226,7 @@
|
|
2226
2226
|
<pre id="out_220"></pre>
|
2227
2227
|
</td>
|
2228
2228
|
<td>
|
2229
|
-
<pre id="exp_220">
|
2229
|
+
<pre id="exp_220">1</pre>
|
2230
2230
|
</td>
|
2231
2231
|
</tr>
|
2232
2232
|
|
@@ -2236,7 +2236,7 @@
|
|
2236
2236
|
<pre id="out_221"></pre>
|
2237
2237
|
</td>
|
2238
2238
|
<td>
|
2239
|
-
<pre id="exp_221">
|
2239
|
+
<pre id="exp_221">2</pre>
|
2240
2240
|
</td>
|
2241
2241
|
</tr>
|
2242
2242
|
|
@@ -2246,7 +2246,7 @@
|
|
2246
2246
|
<pre id="out_222"></pre>
|
2247
2247
|
</td>
|
2248
2248
|
<td>
|
2249
|
-
<pre id="exp_222"
|
2249
|
+
<pre id="exp_222">"hallo"</pre>
|
2250
2250
|
</td>
|
2251
2251
|
</tr>
|
2252
2252
|
|
@@ -2256,7 +2256,7 @@
|
|
2256
2256
|
<pre id="out_223"></pre>
|
2257
2257
|
</td>
|
2258
2258
|
<td>
|
2259
|
-
<pre id="exp_223">
|
2259
|
+
<pre id="exp_223">[]</pre>
|
2260
2260
|
</td>
|
2261
2261
|
</tr>
|
2262
2262
|
|
@@ -2266,7 +2266,7 @@
|
|
2266
2266
|
<pre id="out_224"></pre>
|
2267
2267
|
</td>
|
2268
2268
|
<td>
|
2269
|
-
<pre id="exp_224"
|
2269
|
+
<pre id="exp_224">--</pre>
|
2270
2270
|
</td>
|
2271
2271
|
</tr>
|
2272
2272
|
|
@@ -2276,7 +2276,7 @@
|
|
2276
2276
|
<pre id="out_225"></pre>
|
2277
2277
|
</td>
|
2278
2278
|
<td>
|
2279
|
-
<pre id="exp_225">
|
2279
|
+
<pre id="exp_225">1</pre>
|
2280
2280
|
</td>
|
2281
2281
|
</tr>
|
2282
2282
|
|
@@ -2286,7 +2286,7 @@
|
|
2286
2286
|
<pre id="out_226"></pre>
|
2287
2287
|
</td>
|
2288
2288
|
<td>
|
2289
|
-
<pre id="exp_226">
|
2289
|
+
<pre id="exp_226">2</pre>
|
2290
2290
|
</td>
|
2291
2291
|
</tr>
|
2292
2292
|
|
@@ -2296,7 +2296,7 @@
|
|
2296
2296
|
<pre id="out_227"></pre>
|
2297
2297
|
</td>
|
2298
2298
|
<td>
|
2299
|
-
<pre id="exp_227"
|
2299
|
+
<pre id="exp_227">9</pre>
|
2300
2300
|
</td>
|
2301
2301
|
</tr>
|
2302
2302
|
|
@@ -2306,7 +2306,7 @@
|
|
2306
2306
|
<pre id="out_228"></pre>
|
2307
2307
|
</td>
|
2308
2308
|
<td>
|
2309
|
-
<pre id="exp_228">
|
2309
|
+
<pre id="exp_228">[]</pre>
|
2310
2310
|
</td>
|
2311
2311
|
</tr>
|
2312
2312
|
|
@@ -2316,7 +2316,7 @@
|
|
2316
2316
|
<pre id="out_229"></pre>
|
2317
2317
|
</td>
|
2318
2318
|
<td>
|
2319
|
-
<pre id="exp_229"
|
2319
|
+
<pre id="exp_229">--</pre>
|
2320
2320
|
</td>
|
2321
2321
|
</tr>
|
2322
2322
|
|
@@ -2326,7 +2326,7 @@
|
|
2326
2326
|
<pre id="out_230"></pre>
|
2327
2327
|
</td>
|
2328
2328
|
<td>
|
2329
|
-
<pre id="exp_230">
|
2329
|
+
<pre id="exp_230">1</pre>
|
2330
2330
|
</td>
|
2331
2331
|
</tr>
|
2332
2332
|
|
@@ -2336,7 +2336,7 @@
|
|
2336
2336
|
<pre id="out_231"></pre>
|
2337
2337
|
</td>
|
2338
2338
|
<td>
|
2339
|
-
<pre id="exp_231">
|
2339
|
+
<pre id="exp_231">2</pre>
|
2340
2340
|
</td>
|
2341
2341
|
</tr>
|
2342
2342
|
|
@@ -2346,7 +2346,7 @@
|
|
2346
2346
|
<pre id="out_232"></pre>
|
2347
2347
|
</td>
|
2348
2348
|
<td>
|
2349
|
-
<pre id="exp_232"
|
2349
|
+
<pre id="exp_232">9</pre>
|
2350
2350
|
</td>
|
2351
2351
|
</tr>
|
2352
2352
|
|
@@ -2356,7 +2356,7 @@
|
|
2356
2356
|
<pre id="out_233"></pre>
|
2357
2357
|
</td>
|
2358
2358
|
<td>
|
2359
|
-
<pre id="exp_233">
|
2359
|
+
<pre id="exp_233">[5]</pre>
|
2360
2360
|
</td>
|
2361
2361
|
</tr>
|
2362
2362
|
|
@@ -2366,7 +2366,7 @@
|
|
2366
2366
|
<pre id="out_234"></pre>
|
2367
2367
|
</td>
|
2368
2368
|
<td>
|
2369
|
-
<pre id="exp_234"
|
2369
|
+
<pre id="exp_234">--</pre>
|
2370
2370
|
</td>
|
2371
2371
|
</tr>
|
2372
2372
|
|
@@ -2376,7 +2376,7 @@
|
|
2376
2376
|
<pre id="out_235"></pre>
|
2377
2377
|
</td>
|
2378
2378
|
<td>
|
2379
|
-
<pre id="exp_235">
|
2379
|
+
<pre id="exp_235">1</pre>
|
2380
2380
|
</td>
|
2381
2381
|
</tr>
|
2382
2382
|
|
@@ -2386,7 +2386,7 @@
|
|
2386
2386
|
<pre id="out_236"></pre>
|
2387
2387
|
</td>
|
2388
2388
|
<td>
|
2389
|
-
<pre id="exp_236">
|
2389
|
+
<pre id="exp_236">2</pre>
|
2390
2390
|
</td>
|
2391
2391
|
</tr>
|
2392
2392
|
|
@@ -2396,7 +2396,7 @@
|
|
2396
2396
|
<pre id="out_237"></pre>
|
2397
2397
|
</td>
|
2398
2398
|
<td>
|
2399
|
-
<pre id="exp_237"
|
2399
|
+
<pre id="exp_237">9</pre>
|
2400
2400
|
</td>
|
2401
2401
|
</tr>
|
2402
2402
|
|
@@ -2406,7 +2406,7 @@
|
|
2406
2406
|
<pre id="out_238"></pre>
|
2407
2407
|
</td>
|
2408
2408
|
<td>
|
2409
|
-
<pre id="exp_238">
|
2409
|
+
<pre id="exp_238">[5, 6]</pre>
|
2410
2410
|
</td>
|
2411
2411
|
</tr>
|
2412
2412
|
|
@@ -2416,7 +2416,7 @@
|
|
2416
2416
|
<pre id="out_239"></pre>
|
2417
2417
|
</td>
|
2418
2418
|
<td>
|
2419
|
-
<pre id="exp_239"
|
2419
|
+
<pre id="exp_239">--</pre>
|
2420
2420
|
</td>
|
2421
2421
|
</tr>
|
2422
2422
|
|
@@ -2426,7 +2426,7 @@
|
|
2426
2426
|
<pre id="out_240"></pre>
|
2427
2427
|
</td>
|
2428
2428
|
<td>
|
2429
|
-
<pre id="exp_240">
|
2429
|
+
<pre id="exp_240">1</pre>
|
2430
2430
|
</td>
|
2431
2431
|
</tr>
|
2432
2432
|
|
@@ -2436,7 +2436,7 @@
|
|
2436
2436
|
<pre id="out_241"></pre>
|
2437
2437
|
</td>
|
2438
2438
|
<td>
|
2439
|
-
<pre id="exp_241">
|
2439
|
+
<pre id="exp_241">2</pre>
|
2440
2440
|
</td>
|
2441
2441
|
</tr>
|
2442
2442
|
|
@@ -2446,7 +2446,7 @@
|
|
2446
2446
|
<pre id="out_242"></pre>
|
2447
2447
|
</td>
|
2448
2448
|
<td>
|
2449
|
-
<pre id="exp_242">
|
2449
|
+
<pre id="exp_242">9</pre>
|
2450
2450
|
</td>
|
2451
2451
|
</tr>
|
2452
2452
|
|
@@ -2456,7 +2456,7 @@
|
|
2456
2456
|
<pre id="out_243"></pre>
|
2457
2457
|
</td>
|
2458
2458
|
<td>
|
2459
|
-
<pre id="exp_243">
|
2459
|
+
<pre id="exp_243">[5, 6, 7, 8, 9, 10, 11, 12]</pre>
|
2460
2460
|
</td>
|
2461
2461
|
</tr>
|
2462
2462
|
|
@@ -2466,7 +2466,7 @@
|
|
2466
2466
|
<pre id="out_244"></pre>
|
2467
2467
|
</td>
|
2468
2468
|
<td>
|
2469
|
-
<pre id="exp_244"
|
2469
|
+
<pre id="exp_244">~~~~~~~~~~~~~~~~~~~~</pre>
|
2470
2470
|
</td>
|
2471
2471
|
</tr>
|
2472
2472
|
|
@@ -2476,7 +2476,7 @@
|
|
2476
2476
|
<pre id="out_245"></pre>
|
2477
2477
|
</td>
|
2478
2478
|
<td>
|
2479
|
-
<pre id="exp_245"
|
2479
|
+
<pre id="exp_245">Test array</pre>
|
2480
2480
|
</td>
|
2481
2481
|
</tr>
|
2482
2482
|
|
@@ -2486,7 +2486,7 @@
|
|
2486
2486
|
<pre id="out_246"></pre>
|
2487
2487
|
</td>
|
2488
2488
|
<td>
|
2489
|
-
<pre id="exp_246"
|
2489
|
+
<pre id="exp_246">~~~~~~~~~~~~~~~~~~~~</pre>
|
2490
2490
|
</td>
|
2491
2491
|
</tr>
|
2492
2492
|
|
@@ -2496,7 +2496,7 @@
|
|
2496
2496
|
<pre id="out_247"></pre>
|
2497
2497
|
</td>
|
2498
2498
|
<td>
|
2499
|
-
<pre id="exp_247"
|
2499
|
+
<pre id="exp_247">"b"</pre>
|
2500
2500
|
</td>
|
2501
2501
|
</tr>
|
2502
2502
|
|
@@ -2506,7 +2506,7 @@
|
|
2506
2506
|
<pre id="out_248"></pre>
|
2507
2507
|
</td>
|
2508
2508
|
<td>
|
2509
|
-
<pre id="exp_248">
|
2509
|
+
<pre id="exp_248">["a", "c"]</pre>
|
2510
2510
|
</td>
|
2511
2511
|
</tr>
|
2512
2512
|
|
@@ -2516,7 +2516,7 @@
|
|
2516
2516
|
<pre id="out_249"></pre>
|
2517
2517
|
</td>
|
2518
2518
|
<td>
|
2519
|
-
<pre id="exp_249">
|
2519
|
+
<pre id="exp_249">nil</pre>
|
2520
2520
|
</td>
|
2521
2521
|
</tr>
|
2522
2522
|
|
@@ -2526,7 +2526,7 @@
|
|
2526
2526
|
<pre id="out_250"></pre>
|
2527
2527
|
</td>
|
2528
2528
|
<td>
|
2529
|
-
<pre id="exp_250">
|
2529
|
+
<pre id="exp_250">test native JS array mapping</pre>
|
2530
2530
|
</td>
|
2531
2531
|
</tr>
|
2532
2532
|
|
@@ -2536,7 +2536,7 @@
|
|
2536
2536
|
<pre id="out_251"></pre>
|
2537
2537
|
</td>
|
2538
2538
|
<td>
|
2539
|
-
<pre id="exp_251">
|
2539
|
+
<pre id="exp_251">[1, 2, nil, [nil, nil, 4]]</pre>
|
2540
2540
|
</td>
|
2541
2541
|
</tr>
|
2542
2542
|
|
@@ -2546,7 +2546,7 @@
|
|
2546
2546
|
<pre id="out_252"></pre>
|
2547
2547
|
</td>
|
2548
2548
|
<td>
|
2549
|
-
<pre id="exp_252"
|
2549
|
+
<pre id="exp_252">~~~~~~~~~~~~~~~~~~~~</pre>
|
2550
2550
|
</td>
|
2551
2551
|
</tr>
|
2552
2552
|
|
@@ -2556,7 +2556,7 @@
|
|
2556
2556
|
<pre id="out_253"></pre>
|
2557
2557
|
</td>
|
2558
2558
|
<td>
|
2559
|
-
<pre id="exp_253"
|
2559
|
+
<pre id="exp_253">Test eql</pre>
|
2560
2560
|
</td>
|
2561
2561
|
</tr>
|
2562
2562
|
|
@@ -2566,7 +2566,7 @@
|
|
2566
2566
|
<pre id="out_254"></pre>
|
2567
2567
|
</td>
|
2568
2568
|
<td>
|
2569
|
-
<pre id="exp_254"
|
2569
|
+
<pre id="exp_254">~~~~~~~~~~~~~~~~~~~~</pre>
|
2570
2570
|
</td>
|
2571
2571
|
</tr>
|
2572
2572
|
|
@@ -2576,7 +2576,7 @@
|
|
2576
2576
|
<pre id="out_255"></pre>
|
2577
2577
|
</td>
|
2578
2578
|
<td>
|
2579
|
-
<pre id="exp_255"
|
2579
|
+
<pre id="exp_255">true</pre>
|
2580
2580
|
</td>
|
2581
2581
|
</tr>
|
2582
2582
|
|
@@ -2586,7 +2586,7 @@
|
|
2586
2586
|
<pre id="out_256"></pre>
|
2587
2587
|
</td>
|
2588
2588
|
<td>
|
2589
|
-
<pre id="exp_256">
|
2589
|
+
<pre id="exp_256">false</pre>
|
2590
2590
|
</td>
|
2591
2591
|
</tr>
|
2592
2592
|
|
@@ -2596,7 +2596,7 @@
|
|
2596
2596
|
<pre id="out_257"></pre>
|
2597
2597
|
</td>
|
2598
2598
|
<td>
|
2599
|
-
<pre id="exp_257">
|
2599
|
+
<pre id="exp_257">false</pre>
|
2600
2600
|
</td>
|
2601
2601
|
</tr>
|
2602
2602
|
|
@@ -2606,7 +2606,7 @@
|
|
2606
2606
|
<pre id="out_258"></pre>
|
2607
2607
|
</td>
|
2608
2608
|
<td>
|
2609
|
-
<pre id="exp_258">
|
2609
|
+
<pre id="exp_258">true</pre>
|
2610
2610
|
</td>
|
2611
2611
|
</tr>
|
2612
2612
|
|
@@ -2616,7 +2616,7 @@
|
|
2616
2616
|
<pre id="out_259"></pre>
|
2617
2617
|
</td>
|
2618
2618
|
<td>
|
2619
|
-
<pre id="exp_259">
|
2619
|
+
<pre id="exp_259">false</pre>
|
2620
2620
|
</td>
|
2621
2621
|
</tr>
|
2622
2622
|
|
@@ -2626,7 +2626,7 @@
|
|
2626
2626
|
<pre id="out_260"></pre>
|
2627
2627
|
</td>
|
2628
2628
|
<td>
|
2629
|
-
<pre id="exp_260"
|
2629
|
+
<pre id="exp_260">~~~~~~~~~~~~~~~~~~~~</pre>
|
2630
2630
|
</td>
|
2631
2631
|
</tr>
|
2632
2632
|
|
@@ -2636,7 +2636,7 @@
|
|
2636
2636
|
<pre id="out_261"></pre>
|
2637
2637
|
</td>
|
2638
2638
|
<td>
|
2639
|
-
<pre id="exp_261">
|
2639
|
+
<pre id="exp_261">Test send</pre>
|
2640
2640
|
</td>
|
2641
2641
|
</tr>
|
2642
2642
|
|
@@ -2646,7 +2646,7 @@
|
|
2646
2646
|
<pre id="out_262"></pre>
|
2647
2647
|
</td>
|
2648
2648
|
<td>
|
2649
|
-
<pre id="exp_262"
|
2649
|
+
<pre id="exp_262">~~~~~~~~~~~~~~~~~~~~</pre>
|
2650
2650
|
</td>
|
2651
2651
|
</tr>
|
2652
2652
|
|
@@ -2656,7 +2656,7 @@
|
|
2656
2656
|
<pre id="out_263"></pre>
|
2657
2657
|
</td>
|
2658
2658
|
<td>
|
2659
|
-
<pre id="exp_263">
|
2659
|
+
<pre id="exp_263">send</pre>
|
2660
2660
|
</td>
|
2661
2661
|
</tr>
|
2662
2662
|
|
@@ -2666,7 +2666,7 @@
|
|
2666
2666
|
<pre id="out_264"></pre>
|
2667
2667
|
</td>
|
2668
2668
|
<td>
|
2669
|
-
<pre id="exp_264">
|
2669
|
+
<pre id="exp_264">1</pre>
|
2670
2670
|
</td>
|
2671
2671
|
</tr>
|
2672
2672
|
|
@@ -2676,7 +2676,7 @@
|
|
2676
2676
|
<pre id="out_265"></pre>
|
2677
2677
|
</td>
|
2678
2678
|
<td>
|
2679
|
-
<pre id="exp_265">
|
2679
|
+
<pre id="exp_265">2</pre>
|
2680
2680
|
</td>
|
2681
2681
|
</tr>
|
2682
2682
|
|
@@ -2686,7 +2686,7 @@
|
|
2686
2686
|
<pre id="out_266"></pre>
|
2687
2687
|
</td>
|
2688
2688
|
<td>
|
2689
|
-
<pre id="exp_266">
|
2689
|
+
<pre id="exp_266">nil</pre>
|
2690
2690
|
</td>
|
2691
2691
|
</tr>
|
2692
2692
|
|
@@ -2696,7 +2696,7 @@
|
|
2696
2696
|
<pre id="out_267"></pre>
|
2697
2697
|
</td>
|
2698
2698
|
<td>
|
2699
|
-
<pre id="exp_267">
|
2699
|
+
<pre id="exp_267">"in B"</pre>
|
2700
2700
|
</td>
|
2701
2701
|
</tr>
|
2702
2702
|
|
@@ -2706,7 +2706,7 @@
|
|
2706
2706
|
<pre id="out_268"></pre>
|
2707
2707
|
</td>
|
2708
2708
|
<td>
|
2709
|
-
<pre id="exp_268">
|
2709
|
+
<pre id="exp_268">1</pre>
|
2710
2710
|
</td>
|
2711
2711
|
</tr>
|
2712
2712
|
|
@@ -2716,7 +2716,7 @@
|
|
2716
2716
|
<pre id="out_269"></pre>
|
2717
2717
|
</td>
|
2718
2718
|
<td>
|
2719
|
-
<pre id="exp_269">
|
2719
|
+
<pre id="exp_269">2</pre>
|
2720
2720
|
</td>
|
2721
2721
|
</tr>
|
2722
2722
|
|
@@ -2726,7 +2726,7 @@
|
|
2726
2726
|
<pre id="out_270"></pre>
|
2727
2727
|
</td>
|
2728
2728
|
<td>
|
2729
|
-
<pre id="exp_270">
|
2729
|
+
<pre id="exp_270">nil</pre>
|
2730
2730
|
</td>
|
2731
2731
|
</tr>
|
2732
2732
|
|
@@ -2736,7 +2736,7 @@
|
|
2736
2736
|
<pre id="out_271"></pre>
|
2737
2737
|
</td>
|
2738
2738
|
<td>
|
2739
|
-
<pre id="exp_271">
|
2739
|
+
<pre id="exp_271">respond_to?</pre>
|
2740
2740
|
</td>
|
2741
2741
|
</tr>
|
2742
2742
|
|
@@ -2746,7 +2746,7 @@
|
|
2746
2746
|
<pre id="out_272"></pre>
|
2747
2747
|
</td>
|
2748
2748
|
<td>
|
2749
|
-
<pre id="exp_272">
|
2749
|
+
<pre id="exp_272">true</pre>
|
2750
2750
|
</td>
|
2751
2751
|
</tr>
|
2752
2752
|
|
@@ -2756,7 +2756,7 @@
|
|
2756
2756
|
<pre id="out_273"></pre>
|
2757
2757
|
</td>
|
2758
2758
|
<td>
|
2759
|
-
<pre id="exp_273">
|
2759
|
+
<pre id="exp_273">true</pre>
|
2760
2760
|
</td>
|
2761
2761
|
</tr>
|
2762
2762
|
|
@@ -2766,7 +2766,7 @@
|
|
2766
2766
|
<pre id="out_274"></pre>
|
2767
2767
|
</td>
|
2768
2768
|
<td>
|
2769
|
-
<pre id="exp_274">
|
2769
|
+
<pre id="exp_274">true</pre>
|
2770
2770
|
</td>
|
2771
2771
|
</tr>
|
2772
2772
|
|
@@ -2776,7 +2776,7 @@
|
|
2776
2776
|
<pre id="out_275"></pre>
|
2777
2777
|
</td>
|
2778
2778
|
<td>
|
2779
|
-
<pre id="exp_275">
|
2779
|
+
<pre id="exp_275">false</pre>
|
2780
2780
|
</td>
|
2781
2781
|
</tr>
|
2782
2782
|
|
@@ -2786,7 +2786,7 @@
|
|
2786
2786
|
<pre id="out_276"></pre>
|
2787
2787
|
</td>
|
2788
2788
|
<td>
|
2789
|
-
<pre id="exp_276"
|
2789
|
+
<pre id="exp_276">false</pre>
|
2790
2790
|
</td>
|
2791
2791
|
</tr>
|
2792
2792
|
|
@@ -2796,7 +2796,7 @@
|
|
2796
2796
|
<pre id="out_277"></pre>
|
2797
2797
|
</td>
|
2798
2798
|
<td>
|
2799
|
-
<pre id="exp_277">
|
2799
|
+
<pre id="exp_277">method_missing</pre>
|
2800
2800
|
</td>
|
2801
2801
|
</tr>
|
2802
2802
|
|
@@ -2806,7 +2806,7 @@
|
|
2806
2806
|
<pre id="out_278"></pre>
|
2807
2807
|
</td>
|
2808
2808
|
<td>
|
2809
|
-
<pre id="exp_278"
|
2809
|
+
<pre id="exp_278">false</pre>
|
2810
2810
|
</td>
|
2811
2811
|
</tr>
|
2812
2812
|
|
@@ -2816,7 +2816,7 @@
|
|
2816
2816
|
<pre id="out_279"></pre>
|
2817
2817
|
</td>
|
2818
2818
|
<td>
|
2819
|
-
<pre id="exp_279">
|
2819
|
+
<pre id="exp_279">"mm: blah_blah, 123"</pre>
|
2820
2820
|
</td>
|
2821
2821
|
</tr>
|
2822
2822
|
|
@@ -2826,7 +2826,7 @@
|
|
2826
2826
|
<pre id="out_280"></pre>
|
2827
2827
|
</td>
|
2828
2828
|
<td>
|
2829
|
-
<pre id="exp_280"
|
2829
|
+
<pre id="exp_280">catched!!!</pre>
|
2830
2830
|
</td>
|
2831
2831
|
</tr>
|
2832
2832
|
|
@@ -2836,7 +2836,7 @@
|
|
2836
2836
|
<pre id="out_281"></pre>
|
2837
2837
|
</td>
|
2838
2838
|
<td>
|
2839
|
-
<pre id="exp_281">
|
2839
|
+
<pre id="exp_281">"goood"</pre>
|
2840
2840
|
</td>
|
2841
2841
|
</tr>
|
2842
2842
|
|
@@ -2846,7 +2846,7 @@
|
|
2846
2846
|
<pre id="out_282"></pre>
|
2847
2847
|
</td>
|
2848
2848
|
<td>
|
2849
|
-
<pre id="exp_282"
|
2849
|
+
<pre id="exp_282">class Method</pre>
|
2850
2850
|
</td>
|
2851
2851
|
</tr>
|
2852
2852
|
|
@@ -2856,7 +2856,7 @@
|
|
2856
2856
|
<pre id="out_283"></pre>
|
2857
2857
|
</td>
|
2858
2858
|
<td>
|
2859
|
-
<pre id="exp_283"
|
2859
|
+
<pre id="exp_283">#<Method: String#to_s></pre>
|
2860
2860
|
</td>
|
2861
2861
|
</tr>
|
2862
2862
|
|
@@ -2866,7 +2866,7 @@
|
|
2866
2866
|
<pre id="out_284"></pre>
|
2867
2867
|
</td>
|
2868
2868
|
<td>
|
2869
|
-
<pre id="exp_284"
|
2869
|
+
<pre id="exp_284">"hallo"</pre>
|
2870
2870
|
</td>
|
2871
2871
|
</tr>
|
2872
2872
|
|
@@ -2876,7 +2876,7 @@
|
|
2876
2876
|
<pre id="out_285"></pre>
|
2877
2877
|
</td>
|
2878
2878
|
<td>
|
2879
|
-
<pre id="exp_285"
|
2879
|
+
<pre id="exp_285">#<Method: Array#+></pre>
|
2880
2880
|
</td>
|
2881
2881
|
</tr>
|
2882
2882
|
|
@@ -2886,7 +2886,7 @@
|
|
2886
2886
|
<pre id="out_286"></pre>
|
2887
2887
|
</td>
|
2888
2888
|
<td>
|
2889
|
-
<pre id="exp_286">2</pre>
|
2889
|
+
<pre id="exp_286">[1, 2, 3, 2, 3]</pre>
|
2890
2890
|
</td>
|
2891
2891
|
</tr>
|
2892
2892
|
|
@@ -2896,7 +2896,7 @@
|
|
2896
2896
|
<pre id="out_287"></pre>
|
2897
2897
|
</td>
|
2898
2898
|
<td>
|
2899
|
-
<pre id="exp_287"
|
2899
|
+
<pre id="exp_287">#<Method: Array#+></pre>
|
2900
2900
|
</td>
|
2901
2901
|
</tr>
|
2902
2902
|
|
@@ -2906,7 +2906,7 @@
|
|
2906
2906
|
<pre id="out_288"></pre>
|
2907
2907
|
</td>
|
2908
2908
|
<td>
|
2909
|
-
<pre id="exp_288">
|
2909
|
+
<pre id="exp_288">[1, 2, 3]</pre>
|
2910
2910
|
</td>
|
2911
2911
|
</tr>
|
2912
2912
|
|
@@ -2916,7 +2916,7 @@
|
|
2916
2916
|
<pre id="out_289"></pre>
|
2917
2917
|
</td>
|
2918
2918
|
<td>
|
2919
|
-
<pre id="exp_289"
|
2919
|
+
<pre id="exp_289">~~~~~~~~~~~~~~~~~~~~</pre>
|
2920
2920
|
</td>
|
2921
2921
|
</tr>
|
2922
2922
|
|
@@ -2926,7 +2926,7 @@
|
|
2926
2926
|
<pre id="out_290"></pre>
|
2927
2927
|
</td>
|
2928
2928
|
<td>
|
2929
|
-
<pre id="exp_290">
|
2929
|
+
<pre id="exp_290">Test range</pre>
|
2930
2930
|
</td>
|
2931
2931
|
</tr>
|
2932
2932
|
|
@@ -2936,7 +2936,7 @@
|
|
2936
2936
|
<pre id="out_291"></pre>
|
2937
2937
|
</td>
|
2938
2938
|
<td>
|
2939
|
-
<pre id="exp_291"
|
2939
|
+
<pre id="exp_291">~~~~~~~~~~~~~~~~~~~~</pre>
|
2940
2940
|
</td>
|
2941
2941
|
</tr>
|
2942
2942
|
|
@@ -2946,7 +2946,7 @@
|
|
2946
2946
|
<pre id="out_292"></pre>
|
2947
2947
|
</td>
|
2948
2948
|
<td>
|
2949
|
-
<pre id="exp_292">
|
2949
|
+
<pre id="exp_292">0</pre>
|
2950
2950
|
</td>
|
2951
2951
|
</tr>
|
2952
2952
|
|
@@ -2956,7 +2956,7 @@
|
|
2956
2956
|
<pre id="out_293"></pre>
|
2957
2957
|
</td>
|
2958
2958
|
<td>
|
2959
|
-
<pre id="exp_293">
|
2959
|
+
<pre id="exp_293">2</pre>
|
2960
2960
|
</td>
|
2961
2961
|
</tr>
|
2962
2962
|
|
@@ -2966,7 +2966,7 @@
|
|
2966
2966
|
<pre id="out_294"></pre>
|
2967
2967
|
</td>
|
2968
2968
|
<td>
|
2969
|
-
<pre id="exp_294">
|
2969
|
+
<pre id="exp_294">0..2</pre>
|
2970
2970
|
</td>
|
2971
2971
|
</tr>
|
2972
2972
|
|
@@ -2976,7 +2976,7 @@
|
|
2976
2976
|
<pre id="out_295"></pre>
|
2977
2977
|
</td>
|
2978
2978
|
<td>
|
2979
|
-
<pre id="exp_295">
|
2979
|
+
<pre id="exp_295">"1..6"</pre>
|
2980
2980
|
</td>
|
2981
2981
|
</tr>
|
2982
2982
|
|
@@ -2986,7 +2986,7 @@
|
|
2986
2986
|
<pre id="out_296"></pre>
|
2987
2987
|
</td>
|
2988
2988
|
<td>
|
2989
|
-
<pre id="exp_296">1</pre>
|
2989
|
+
<pre id="exp_296">"1...2"</pre>
|
2990
2990
|
</td>
|
2991
2991
|
</tr>
|
2992
2992
|
|
@@ -2996,7 +2996,7 @@
|
|
2996
2996
|
<pre id="out_297"></pre>
|
2997
2997
|
</td>
|
2998
2998
|
<td>
|
2999
|
-
<pre id="exp_297">2</pre>
|
2999
|
+
<pre id="exp_297">"0..2"</pre>
|
3000
3000
|
</td>
|
3001
3001
|
</tr>
|
3002
3002
|
|
@@ -3006,7 +3006,7 @@
|
|
3006
3006
|
<pre id="out_298"></pre>
|
3007
3007
|
</td>
|
3008
3008
|
<td>
|
3009
|
-
<pre id="exp_298">
|
3009
|
+
<pre id="exp_298">"0...2"</pre>
|
3010
3010
|
</td>
|
3011
3011
|
</tr>
|
3012
3012
|
|
@@ -3016,7 +3016,7 @@
|
|
3016
3016
|
<pre id="out_299"></pre>
|
3017
3017
|
</td>
|
3018
3018
|
<td>
|
3019
|
-
<pre id="exp_299">
|
3019
|
+
<pre id="exp_299">0</pre>
|
3020
3020
|
</td>
|
3021
3021
|
</tr>
|
3022
3022
|
|
@@ -3026,7 +3026,7 @@
|
|
3026
3026
|
<pre id="out_300"></pre>
|
3027
3027
|
</td>
|
3028
3028
|
<td>
|
3029
|
-
<pre id="exp_300">
|
3029
|
+
<pre id="exp_300">1</pre>
|
3030
3030
|
</td>
|
3031
3031
|
</tr>
|
3032
3032
|
|
@@ -3036,7 +3036,7 @@
|
|
3036
3036
|
<pre id="out_301"></pre>
|
3037
3037
|
</td>
|
3038
3038
|
<td>
|
3039
|
-
<pre id="exp_301">
|
3039
|
+
<pre id="exp_301">2</pre>
|
3040
3040
|
</td>
|
3041
3041
|
</tr>
|
3042
3042
|
|
@@ -3046,7 +3046,7 @@
|
|
3046
3046
|
<pre id="out_302"></pre>
|
3047
3047
|
</td>
|
3048
3048
|
<td>
|
3049
|
-
<pre id="exp_302">
|
3049
|
+
<pre id="exp_302">3</pre>
|
3050
3050
|
</td>
|
3051
3051
|
</tr>
|
3052
3052
|
|
@@ -3056,7 +3056,7 @@
|
|
3056
3056
|
<pre id="out_303"></pre>
|
3057
3057
|
</td>
|
3058
3058
|
<td>
|
3059
|
-
<pre id="exp_303">
|
3059
|
+
<pre id="exp_303">4</pre>
|
3060
3060
|
</td>
|
3061
3061
|
</tr>
|
3062
3062
|
|
@@ -3066,7 +3066,7 @@
|
|
3066
3066
|
<pre id="out_304"></pre>
|
3067
3067
|
</td>
|
3068
3068
|
<td>
|
3069
|
-
<pre id="exp_304">
|
3069
|
+
<pre id="exp_304">0</pre>
|
3070
3070
|
</td>
|
3071
3071
|
</tr>
|
3072
3072
|
|
@@ -3076,7 +3076,7 @@
|
|
3076
3076
|
<pre id="out_305"></pre>
|
3077
3077
|
</td>
|
3078
3078
|
<td>
|
3079
|
-
<pre id="exp_305">
|
3079
|
+
<pre id="exp_305">1</pre>
|
3080
3080
|
</td>
|
3081
3081
|
</tr>
|
3082
3082
|
|
@@ -3086,7 +3086,7 @@
|
|
3086
3086
|
<pre id="out_306"></pre>
|
3087
3087
|
</td>
|
3088
3088
|
<td>
|
3089
|
-
<pre id="exp_306">
|
3089
|
+
<pre id="exp_306">2</pre>
|
3090
3090
|
</td>
|
3091
3091
|
</tr>
|
3092
3092
|
|
@@ -3096,7 +3096,7 @@
|
|
3096
3096
|
<pre id="out_307"></pre>
|
3097
3097
|
</td>
|
3098
3098
|
<td>
|
3099
|
-
<pre id="exp_307">
|
3099
|
+
<pre id="exp_307">3</pre>
|
3100
3100
|
</td>
|
3101
3101
|
</tr>
|
3102
3102
|
|
@@ -3106,7 +3106,7 @@
|
|
3106
3106
|
<pre id="out_308"></pre>
|
3107
3107
|
</td>
|
3108
3108
|
<td>
|
3109
|
-
<pre id="exp_308">
|
3109
|
+
<pre id="exp_308">true</pre>
|
3110
3110
|
</td>
|
3111
3111
|
</tr>
|
3112
3112
|
|
@@ -3116,7 +3116,7 @@
|
|
3116
3116
|
<pre id="out_309"></pre>
|
3117
3117
|
</td>
|
3118
3118
|
<td>
|
3119
|
-
<pre id="exp_309">
|
3119
|
+
<pre id="exp_309">false</pre>
|
3120
3120
|
</td>
|
3121
3121
|
</tr>
|
3122
3122
|
|
@@ -3126,7 +3126,7 @@
|
|
3126
3126
|
<pre id="out_310"></pre>
|
3127
3127
|
</td>
|
3128
3128
|
<td>
|
3129
|
-
<pre id="exp_310">
|
3129
|
+
<pre id="exp_310">false</pre>
|
3130
3130
|
</td>
|
3131
3131
|
</tr>
|
3132
3132
|
|
@@ -3136,7 +3136,7 @@
|
|
3136
3136
|
<pre id="out_311"></pre>
|
3137
3137
|
</td>
|
3138
3138
|
<td>
|
3139
|
-
<pre id="exp_311">
|
3139
|
+
<pre id="exp_311">false</pre>
|
3140
3140
|
</td>
|
3141
3141
|
</tr>
|
3142
3142
|
|
@@ -3146,7 +3146,7 @@
|
|
3146
3146
|
<pre id="out_312"></pre>
|
3147
3147
|
</td>
|
3148
3148
|
<td>
|
3149
|
-
<pre id="exp_312">
|
3149
|
+
<pre id="exp_312">true</pre>
|
3150
3150
|
</td>
|
3151
3151
|
</tr>
|
3152
3152
|
|
@@ -3156,7 +3156,7 @@
|
|
3156
3156
|
<pre id="out_313"></pre>
|
3157
3157
|
</td>
|
3158
3158
|
<td>
|
3159
|
-
<pre id="exp_313">
|
3159
|
+
<pre id="exp_313">true</pre>
|
3160
3160
|
</td>
|
3161
3161
|
</tr>
|
3162
3162
|
|
@@ -3166,7 +3166,7 @@
|
|
3166
3166
|
<pre id="out_314"></pre>
|
3167
3167
|
</td>
|
3168
3168
|
<td>
|
3169
|
-
<pre id="exp_314">
|
3169
|
+
<pre id="exp_314">false</pre>
|
3170
3170
|
</td>
|
3171
3171
|
</tr>
|
3172
3172
|
|
@@ -3176,7 +3176,7 @@
|
|
3176
3176
|
<pre id="out_315"></pre>
|
3177
3177
|
</td>
|
3178
3178
|
<td>
|
3179
|
-
<pre id="exp_315">
|
3179
|
+
<pre id="exp_315">[]</pre>
|
3180
3180
|
</td>
|
3181
3181
|
</tr>
|
3182
3182
|
|
@@ -3186,7 +3186,7 @@
|
|
3186
3186
|
<pre id="out_316"></pre>
|
3187
3187
|
</td>
|
3188
3188
|
<td>
|
3189
|
-
<pre id="exp_316">5</pre>
|
3189
|
+
<pre id="exp_316">[-5, -4, -3, -2, -1]</pre>
|
3190
3190
|
</td>
|
3191
3191
|
</tr>
|
3192
3192
|
|
@@ -3196,7 +3196,7 @@
|
|
3196
3196
|
<pre id="out_317"></pre>
|
3197
3197
|
</td>
|
3198
3198
|
<td>
|
3199
|
-
<pre id="exp_317">
|
3199
|
+
<pre id="exp_317">0</pre>
|
3200
3200
|
</td>
|
3201
3201
|
</tr>
|
3202
3202
|
|
@@ -3206,7 +3206,7 @@
|
|
3206
3206
|
<pre id="out_318"></pre>
|
3207
3207
|
</td>
|
3208
3208
|
<td>
|
3209
|
-
<pre id="exp_318">
|
3209
|
+
<pre id="exp_318">0</pre>
|
3210
3210
|
</td>
|
3211
3211
|
</tr>
|
3212
3212
|
|
@@ -3216,7 +3216,7 @@
|
|
3216
3216
|
<pre id="out_319"></pre>
|
3217
3217
|
</td>
|
3218
3218
|
<td>
|
3219
|
-
<pre id="exp_319">
|
3219
|
+
<pre id="exp_319">4</pre>
|
3220
3220
|
</td>
|
3221
3221
|
</tr>
|
3222
3222
|
|
@@ -3226,7 +3226,7 @@
|
|
3226
3226
|
<pre id="out_320"></pre>
|
3227
3227
|
</td>
|
3228
3228
|
<td>
|
3229
|
-
<pre id="exp_320">
|
3229
|
+
<pre id="exp_320">4</pre>
|
3230
3230
|
</td>
|
3231
3231
|
</tr>
|
3232
3232
|
|
@@ -3236,7 +3236,7 @@
|
|
3236
3236
|
<pre id="out_321"></pre>
|
3237
3237
|
</td>
|
3238
3238
|
<td>
|
3239
|
-
<pre id="exp_321">
|
3239
|
+
<pre id="exp_321">false</pre>
|
3240
3240
|
</td>
|
3241
3241
|
</tr>
|
3242
3242
|
|
@@ -3246,7 +3246,7 @@
|
|
3246
3246
|
<pre id="out_322"></pre>
|
3247
3247
|
</td>
|
3248
3248
|
<td>
|
3249
|
-
<pre id="exp_322">
|
3249
|
+
<pre id="exp_322">1</pre>
|
3250
3250
|
</td>
|
3251
3251
|
</tr>
|
3252
3252
|
|
@@ -3256,7 +3256,7 @@
|
|
3256
3256
|
<pre id="out_323"></pre>
|
3257
3257
|
</td>
|
3258
3258
|
<td>
|
3259
|
-
<pre id="exp_323">
|
3259
|
+
<pre id="exp_323">1</pre>
|
3260
3260
|
</td>
|
3261
3261
|
</tr>
|
3262
3262
|
|
@@ -3266,7 +3266,7 @@
|
|
3266
3266
|
<pre id="out_324"></pre>
|
3267
3267
|
</td>
|
3268
3268
|
<td>
|
3269
|
-
<pre id="exp_324">
|
3269
|
+
<pre id="exp_324">5</pre>
|
3270
3270
|
</td>
|
3271
3271
|
</tr>
|
3272
3272
|
|
@@ -3276,7 +3276,7 @@
|
|
3276
3276
|
<pre id="out_325"></pre>
|
3277
3277
|
</td>
|
3278
3278
|
<td>
|
3279
|
-
<pre id="exp_325"
|
3279
|
+
<pre id="exp_325">5</pre>
|
3280
3280
|
</td>
|
3281
3281
|
</tr>
|
3282
3282
|
|
@@ -3286,7 +3286,7 @@
|
|
3286
3286
|
<pre id="out_326"></pre>
|
3287
3287
|
</td>
|
3288
3288
|
<td>
|
3289
|
-
<pre id="exp_326">
|
3289
|
+
<pre id="exp_326">true</pre>
|
3290
3290
|
</td>
|
3291
3291
|
</tr>
|
3292
3292
|
|
@@ -3296,7 +3296,7 @@
|
|
3296
3296
|
<pre id="out_327"></pre>
|
3297
3297
|
</td>
|
3298
3298
|
<td>
|
3299
|
-
<pre id="exp_327"
|
3299
|
+
<pre id="exp_327">true</pre>
|
3300
3300
|
</td>
|
3301
3301
|
</tr>
|
3302
3302
|
|
@@ -3306,7 +3306,7 @@
|
|
3306
3306
|
<pre id="out_328"></pre>
|
3307
3307
|
</td>
|
3308
3308
|
<td>
|
3309
|
-
<pre id="exp_328">
|
3309
|
+
<pre id="exp_328">false</pre>
|
3310
3310
|
</td>
|
3311
3311
|
</tr>
|
3312
3312
|
|
@@ -3316,7 +3316,7 @@
|
|
3316
3316
|
<pre id="out_329"></pre>
|
3317
3317
|
</td>
|
3318
3318
|
<td>
|
3319
|
-
<pre id="exp_329">
|
3319
|
+
<pre id="exp_329">false</pre>
|
3320
3320
|
</td>
|
3321
3321
|
</tr>
|
3322
3322
|
|
@@ -3326,7 +3326,7 @@
|
|
3326
3326
|
<pre id="out_330"></pre>
|
3327
3327
|
</td>
|
3328
3328
|
<td>
|
3329
|
-
<pre id="exp_330"
|
3329
|
+
<pre id="exp_330">true</pre>
|
3330
3330
|
</td>
|
3331
3331
|
</tr>
|
3332
3332
|
|
@@ -3336,7 +3336,7 @@
|
|
3336
3336
|
<pre id="out_331"></pre>
|
3337
3337
|
</td>
|
3338
3338
|
<td>
|
3339
|
-
<pre id="exp_331">
|
3339
|
+
<pre id="exp_331">true</pre>
|
3340
3340
|
</td>
|
3341
3341
|
</tr>
|
3342
3342
|
|
@@ -3346,7 +3346,7 @@
|
|
3346
3346
|
<pre id="out_332"></pre>
|
3347
3347
|
</td>
|
3348
3348
|
<td>
|
3349
|
-
<pre id="exp_332">
|
3349
|
+
<pre id="exp_332">true</pre>
|
3350
3350
|
</td>
|
3351
3351
|
</tr>
|
3352
3352
|
|
@@ -3356,7 +3356,7 @@
|
|
3356
3356
|
<pre id="out_333"></pre>
|
3357
3357
|
</td>
|
3358
3358
|
<td>
|
3359
|
-
<pre id="exp_333"
|
3359
|
+
<pre id="exp_333">false</pre>
|
3360
3360
|
</td>
|
3361
3361
|
</tr>
|
3362
3362
|
|
@@ -3366,7 +3366,7 @@
|
|
3366
3366
|
<pre id="out_334"></pre>
|
3367
3367
|
</td>
|
3368
3368
|
<td>
|
3369
|
-
<pre id="exp_334">
|
3369
|
+
<pre id="exp_334">55</pre>
|
3370
3370
|
</td>
|
3371
3371
|
</tr>
|
3372
3372
|
|
@@ -3376,7 +3376,7 @@
|
|
3376
3376
|
<pre id="out_335"></pre>
|
3377
3377
|
</td>
|
3378
3378
|
<td>
|
3379
|
-
<pre id="exp_335">
|
3379
|
+
<pre id="exp_335">100</pre>
|
3380
3380
|
</td>
|
3381
3381
|
</tr>
|
3382
3382
|
|
@@ -3386,7 +3386,7 @@
|
|
3386
3386
|
<pre id="out_336"></pre>
|
3387
3387
|
</td>
|
3388
3388
|
<td>
|
3389
|
-
<pre id="exp_336">
|
3389
|
+
<pre id="exp_336">54</pre>
|
3390
3390
|
</td>
|
3391
3391
|
</tr>
|
3392
3392
|
|
@@ -3396,7 +3396,7 @@
|
|
3396
3396
|
<pre id="out_337"></pre>
|
3397
3397
|
</td>
|
3398
3398
|
<td>
|
3399
|
-
<pre id="exp_337"
|
3399
|
+
<pre id="exp_337">100</pre>
|
3400
3400
|
</td>
|
3401
3401
|
</tr>
|
3402
3402
|
|
@@ -3406,7 +3406,7 @@
|
|
3406
3406
|
<pre id="out_338"></pre>
|
3407
3407
|
</td>
|
3408
3408
|
<td>
|
3409
|
-
<pre id="exp_338"
|
3409
|
+
<pre id="exp_338">~~~~~~~~~~~~~~~~~~~~</pre>
|
3410
3410
|
</td>
|
3411
3411
|
</tr>
|
3412
3412
|
|
@@ -3416,7 +3416,7 @@
|
|
3416
3416
|
<pre id="out_339"></pre>
|
3417
3417
|
</td>
|
3418
3418
|
<td>
|
3419
|
-
<pre id="exp_339">
|
3419
|
+
<pre id="exp_339">Test massign</pre>
|
3420
3420
|
</td>
|
3421
3421
|
</tr>
|
3422
3422
|
|
@@ -3426,7 +3426,7 @@
|
|
3426
3426
|
<pre id="out_340"></pre>
|
3427
3427
|
</td>
|
3428
3428
|
<td>
|
3429
|
-
<pre id="exp_340"
|
3429
|
+
<pre id="exp_340">~~~~~~~~~~~~~~~~~~~~</pre>
|
3430
3430
|
</td>
|
3431
3431
|
</tr>
|
3432
3432
|
|
@@ -3436,7 +3436,7 @@
|
|
3436
3436
|
<pre id="out_341"></pre>
|
3437
3437
|
</td>
|
3438
3438
|
<td>
|
3439
|
-
<pre id="exp_341"
|
3439
|
+
<pre id="exp_341">1</pre>
|
3440
3440
|
</td>
|
3441
3441
|
</tr>
|
3442
3442
|
|
@@ -3446,7 +3446,7 @@
|
|
3446
3446
|
<pre id="out_342"></pre>
|
3447
3447
|
</td>
|
3448
3448
|
<td>
|
3449
|
-
<pre id="exp_342">
|
3449
|
+
<pre id="exp_342">2</pre>
|
3450
3450
|
</td>
|
3451
3451
|
</tr>
|
3452
3452
|
|
@@ -3456,7 +3456,7 @@
|
|
3456
3456
|
<pre id="out_343"></pre>
|
3457
3457
|
</td>
|
3458
3458
|
<td>
|
3459
|
-
<pre id="exp_343"
|
3459
|
+
<pre id="exp_343">--</pre>
|
3460
3460
|
</td>
|
3461
3461
|
</tr>
|
3462
3462
|
|
@@ -3466,7 +3466,7 @@
|
|
3466
3466
|
<pre id="out_344"></pre>
|
3467
3467
|
</td>
|
3468
3468
|
<td>
|
3469
|
-
<pre id="exp_344">
|
3469
|
+
<pre id="exp_344">1</pre>
|
3470
3470
|
</td>
|
3471
3471
|
</tr>
|
3472
3472
|
|
@@ -3486,7 +3486,7 @@
|
|
3486
3486
|
<pre id="out_346"></pre>
|
3487
3487
|
</td>
|
3488
3488
|
<td>
|
3489
|
-
<pre id="exp_346"
|
3489
|
+
<pre id="exp_346">--</pre>
|
3490
3490
|
</td>
|
3491
3491
|
</tr>
|
3492
3492
|
|
@@ -3496,7 +3496,7 @@
|
|
3496
3496
|
<pre id="out_347"></pre>
|
3497
3497
|
</td>
|
3498
3498
|
<td>
|
3499
|
-
<pre id="exp_347"
|
3499
|
+
<pre id="exp_347">1</pre>
|
3500
3500
|
</td>
|
3501
3501
|
</tr>
|
3502
3502
|
|
@@ -3506,7 +3506,7 @@
|
|
3506
3506
|
<pre id="out_348"></pre>
|
3507
3507
|
</td>
|
3508
3508
|
<td>
|
3509
|
-
<pre id="exp_348">
|
3509
|
+
<pre id="exp_348">2</pre>
|
3510
3510
|
</td>
|
3511
3511
|
</tr>
|
3512
3512
|
|
@@ -3516,7 +3516,7 @@
|
|
3516
3516
|
<pre id="out_349"></pre>
|
3517
3517
|
</td>
|
3518
3518
|
<td>
|
3519
|
-
<pre id="exp_349">
|
3519
|
+
<pre id="exp_349">nil</pre>
|
3520
3520
|
</td>
|
3521
3521
|
</tr>
|
3522
3522
|
|
@@ -3526,7 +3526,7 @@
|
|
3526
3526
|
<pre id="out_350"></pre>
|
3527
3527
|
</td>
|
3528
3528
|
<td>
|
3529
|
-
<pre id="exp_350"
|
3529
|
+
<pre id="exp_350">--</pre>
|
3530
3530
|
</td>
|
3531
3531
|
</tr>
|
3532
3532
|
|
@@ -3536,7 +3536,7 @@
|
|
3536
3536
|
<pre id="out_351"></pre>
|
3537
3537
|
</td>
|
3538
3538
|
<td>
|
3539
|
-
<pre id="exp_351">
|
3539
|
+
<pre id="exp_351">1</pre>
|
3540
3540
|
</td>
|
3541
3541
|
</tr>
|
3542
3542
|
|
@@ -3546,7 +3546,7 @@
|
|
3546
3546
|
<pre id="out_352"></pre>
|
3547
3547
|
</td>
|
3548
3548
|
<td>
|
3549
|
-
<pre id="exp_352">
|
3549
|
+
<pre id="exp_352">2</pre>
|
3550
3550
|
</td>
|
3551
3551
|
</tr>
|
3552
3552
|
|
@@ -3556,7 +3556,7 @@
|
|
3556
3556
|
<pre id="out_353"></pre>
|
3557
3557
|
</td>
|
3558
3558
|
<td>
|
3559
|
-
<pre id="exp_353"
|
3559
|
+
<pre id="exp_353">3</pre>
|
3560
3560
|
</td>
|
3561
3561
|
</tr>
|
3562
3562
|
|
@@ -3566,7 +3566,7 @@
|
|
3566
3566
|
<pre id="out_354"></pre>
|
3567
3567
|
</td>
|
3568
3568
|
<td>
|
3569
|
-
<pre id="exp_354"
|
3569
|
+
<pre id="exp_354">--</pre>
|
3570
3570
|
</td>
|
3571
3571
|
</tr>
|
3572
3572
|
|
@@ -3576,7 +3576,7 @@
|
|
3576
3576
|
<pre id="out_355"></pre>
|
3577
3577
|
</td>
|
3578
3578
|
<td>
|
3579
|
-
<pre id="exp_355">
|
3579
|
+
<pre id="exp_355">swap</pre>
|
3580
3580
|
</td>
|
3581
3581
|
</tr>
|
3582
3582
|
|
@@ -3586,7 +3586,7 @@
|
|
3586
3586
|
<pre id="out_356"></pre>
|
3587
3587
|
</td>
|
3588
3588
|
<td>
|
3589
|
-
<pre id="exp_356">
|
3589
|
+
<pre id="exp_356">1</pre>
|
3590
3590
|
</td>
|
3591
3591
|
</tr>
|
3592
3592
|
|
@@ -3596,7 +3596,7 @@
|
|
3596
3596
|
<pre id="out_357"></pre>
|
3597
3597
|
</td>
|
3598
3598
|
<td>
|
3599
|
-
<pre id="exp_357"
|
3599
|
+
<pre id="exp_357">2</pre>
|
3600
3600
|
</td>
|
3601
3601
|
</tr>
|
3602
3602
|
|
@@ -3606,7 +3606,7 @@
|
|
3606
3606
|
<pre id="out_358"></pre>
|
3607
3607
|
</td>
|
3608
3608
|
<td>
|
3609
|
-
<pre id="exp_358">
|
3609
|
+
<pre id="exp_358">2</pre>
|
3610
3610
|
</td>
|
3611
3611
|
</tr>
|
3612
3612
|
|
@@ -3626,7 +3626,7 @@
|
|
3626
3626
|
<pre id="out_360"></pre>
|
3627
3627
|
</td>
|
3628
3628
|
<td>
|
3629
|
-
<pre id="exp_360"
|
3629
|
+
<pre id="exp_360">--</pre>
|
3630
3630
|
</td>
|
3631
3631
|
</tr>
|
3632
3632
|
|
@@ -3636,7 +3636,7 @@
|
|
3636
3636
|
<pre id="out_361"></pre>
|
3637
3637
|
</td>
|
3638
3638
|
<td>
|
3639
|
-
<pre id="exp_361"
|
3639
|
+
<pre id="exp_361">splat1</pre>
|
3640
3640
|
</td>
|
3641
3641
|
</tr>
|
3642
3642
|
|
@@ -3646,7 +3646,7 @@
|
|
3646
3646
|
<pre id="out_362"></pre>
|
3647
3647
|
</td>
|
3648
3648
|
<td>
|
3649
|
-
<pre id="exp_362">
|
3649
|
+
<pre id="exp_362">1</pre>
|
3650
3650
|
</td>
|
3651
3651
|
</tr>
|
3652
3652
|
|
@@ -3656,7 +3656,7 @@
|
|
3656
3656
|
<pre id="out_363"></pre>
|
3657
3657
|
</td>
|
3658
3658
|
<td>
|
3659
|
-
<pre id="exp_363">
|
3659
|
+
<pre id="exp_363">2</pre>
|
3660
3660
|
</td>
|
3661
3661
|
</tr>
|
3662
3662
|
|
@@ -3676,7 +3676,7 @@
|
|
3676
3676
|
<pre id="out_365"></pre>
|
3677
3677
|
</td>
|
3678
3678
|
<td>
|
3679
|
-
<pre id="exp_365">
|
3679
|
+
<pre id="exp_365">[]</pre>
|
3680
3680
|
</td>
|
3681
3681
|
</tr>
|
3682
3682
|
|
@@ -3686,7 +3686,7 @@
|
|
3686
3686
|
<pre id="out_366"></pre>
|
3687
3687
|
</td>
|
3688
3688
|
<td>
|
3689
|
-
<pre id="exp_366"
|
3689
|
+
<pre id="exp_366">--</pre>
|
3690
3690
|
</td>
|
3691
3691
|
</tr>
|
3692
3692
|
|
@@ -3696,7 +3696,7 @@
|
|
3696
3696
|
<pre id="out_367"></pre>
|
3697
3697
|
</td>
|
3698
3698
|
<td>
|
3699
|
-
<pre id="exp_367"
|
3699
|
+
<pre id="exp_367">splat2</pre>
|
3700
3700
|
</td>
|
3701
3701
|
</tr>
|
3702
3702
|
|
@@ -3706,7 +3706,7 @@
|
|
3706
3706
|
<pre id="out_368"></pre>
|
3707
3707
|
</td>
|
3708
3708
|
<td>
|
3709
|
-
<pre id="exp_368"
|
3709
|
+
<pre id="exp_368">1</pre>
|
3710
3710
|
</td>
|
3711
3711
|
</tr>
|
3712
3712
|
|
@@ -3716,7 +3716,7 @@
|
|
3716
3716
|
<pre id="out_369"></pre>
|
3717
3717
|
</td>
|
3718
3718
|
<td>
|
3719
|
-
<pre id="exp_369">
|
3719
|
+
<pre id="exp_369">[2]</pre>
|
3720
3720
|
</td>
|
3721
3721
|
</tr>
|
3722
3722
|
|
@@ -3726,7 +3726,7 @@
|
|
3726
3726
|
<pre id="out_370"></pre>
|
3727
3727
|
</td>
|
3728
3728
|
<td>
|
3729
|
-
<pre id="exp_370"
|
3729
|
+
<pre id="exp_370">--</pre>
|
3730
3730
|
</td>
|
3731
3731
|
</tr>
|
3732
3732
|
|
@@ -3736,7 +3736,7 @@
|
|
3736
3736
|
<pre id="out_371"></pre>
|
3737
3737
|
</td>
|
3738
3738
|
<td>
|
3739
|
-
<pre id="exp_371">
|
3739
|
+
<pre id="exp_371">splat3</pre>
|
3740
3740
|
</td>
|
3741
3741
|
</tr>
|
3742
3742
|
|
@@ -3746,7 +3746,7 @@
|
|
3746
3746
|
<pre id="out_372"></pre>
|
3747
3747
|
</td>
|
3748
3748
|
<td>
|
3749
|
-
<pre id="exp_372"
|
3749
|
+
<pre id="exp_372">1</pre>
|
3750
3750
|
</td>
|
3751
3751
|
</tr>
|
3752
3752
|
|
@@ -3756,7 +3756,7 @@
|
|
3756
3756
|
<pre id="out_373"></pre>
|
3757
3757
|
</td>
|
3758
3758
|
<td>
|
3759
|
-
<pre id="exp_373">
|
3759
|
+
<pre id="exp_373">[2, 3, 4, 5]</pre>
|
3760
3760
|
</td>
|
3761
3761
|
</tr>
|
3762
3762
|
|
@@ -3766,7 +3766,7 @@
|
|
3766
3766
|
<pre id="out_374"></pre>
|
3767
3767
|
</td>
|
3768
3768
|
<td>
|
3769
|
-
<pre id="exp_374"
|
3769
|
+
<pre id="exp_374">--</pre>
|
3770
3770
|
</td>
|
3771
3771
|
</tr>
|
3772
3772
|
|
@@ -3776,7 +3776,7 @@
|
|
3776
3776
|
<pre id="out_375"></pre>
|
3777
3777
|
</td>
|
3778
3778
|
<td>
|
3779
|
-
<pre id="exp_375">
|
3779
|
+
<pre id="exp_375">splat with globals</pre>
|
3780
3780
|
</td>
|
3781
3781
|
</tr>
|
3782
3782
|
|
@@ -3786,7 +3786,7 @@
|
|
3786
3786
|
<pre id="out_376"></pre>
|
3787
3787
|
</td>
|
3788
3788
|
<td>
|
3789
|
-
<pre id="exp_376">
|
3789
|
+
<pre id="exp_376">nil</pre>
|
3790
3790
|
</td>
|
3791
3791
|
</tr>
|
3792
3792
|
|
@@ -3796,7 +3796,7 @@
|
|
3796
3796
|
<pre id="out_377"></pre>
|
3797
3797
|
</td>
|
3798
3798
|
<td>
|
3799
|
-
<pre id="exp_377">
|
3799
|
+
<pre id="exp_377">nil</pre>
|
3800
3800
|
</td>
|
3801
3801
|
</tr>
|
3802
3802
|
|
@@ -3806,7 +3806,7 @@
|
|
3806
3806
|
<pre id="out_378"></pre>
|
3807
3807
|
</td>
|
3808
3808
|
<td>
|
3809
|
-
<pre id="exp_378">
|
3809
|
+
<pre id="exp_378">1</pre>
|
3810
3810
|
</td>
|
3811
3811
|
</tr>
|
3812
3812
|
|
@@ -3816,7 +3816,7 @@
|
|
3816
3816
|
<pre id="out_379"></pre>
|
3817
3817
|
</td>
|
3818
3818
|
<td>
|
3819
|
-
<pre id="exp_379">
|
3819
|
+
<pre id="exp_379">2</pre>
|
3820
3820
|
</td>
|
3821
3821
|
</tr>
|
3822
3822
|
|
@@ -3826,7 +3826,7 @@
|
|
3826
3826
|
<pre id="out_380"></pre>
|
3827
3827
|
</td>
|
3828
3828
|
<td>
|
3829
|
-
<pre id="exp_380"
|
3829
|
+
<pre id="exp_380">--</pre>
|
3830
3830
|
</td>
|
3831
3831
|
</tr>
|
3832
3832
|
|
@@ -3836,7 +3836,7 @@
|
|
3836
3836
|
<pre id="out_381"></pre>
|
3837
3837
|
</td>
|
3838
3838
|
<td>
|
3839
|
-
<pre id="exp_381"
|
3839
|
+
<pre id="exp_381">~~~~~~~~~~~~~~~~~~~~</pre>
|
3840
3840
|
</td>
|
3841
3841
|
</tr>
|
3842
3842
|
|
@@ -3846,7 +3846,7 @@
|
|
3846
3846
|
<pre id="out_382"></pre>
|
3847
3847
|
</td>
|
3848
3848
|
<td>
|
3849
|
-
<pre id="exp_382">
|
3849
|
+
<pre id="exp_382">Test hot ruby</pre>
|
3850
3850
|
</td>
|
3851
3851
|
</tr>
|
3852
3852
|
|
@@ -3856,7 +3856,7 @@
|
|
3856
3856
|
<pre id="out_383"></pre>
|
3857
3857
|
</td>
|
3858
3858
|
<td>
|
3859
|
-
<pre id="exp_383"
|
3859
|
+
<pre id="exp_383">~~~~~~~~~~~~~~~~~~~~</pre>
|
3860
3860
|
</td>
|
3861
3861
|
</tr>
|
3862
3862
|
|
@@ -3866,7 +3866,7 @@
|
|
3866
3866
|
<pre id="out_384"></pre>
|
3867
3867
|
</td>
|
3868
3868
|
<td>
|
3869
|
-
<pre id="exp_384">
|
3869
|
+
<pre id="exp_384">InsertionSort</pre>
|
3870
3870
|
</td>
|
3871
3871
|
</tr>
|
3872
3872
|
|
@@ -3876,7 +3876,7 @@
|
|
3876
3876
|
<pre id="out_385"></pre>
|
3877
3877
|
</td>
|
3878
3878
|
<td>
|
3879
|
-
<pre id="exp_385">
|
3879
|
+
<pre id="exp_385">Before insertion sort:</pre>
|
3880
3880
|
</td>
|
3881
3881
|
</tr>
|
3882
3882
|
|
@@ -3886,7 +3886,7 @@
|
|
3886
3886
|
<pre id="out_386"></pre>
|
3887
3887
|
</td>
|
3888
3888
|
<td>
|
3889
|
-
<pre id="exp_386">
|
3889
|
+
<pre id="exp_386">[3, 6, 2, 5, 3, 7, 1, 8]</pre>
|
3890
3890
|
</td>
|
3891
3891
|
</tr>
|
3892
3892
|
|
@@ -3896,7 +3896,7 @@
|
|
3896
3896
|
<pre id="out_387"></pre>
|
3897
3897
|
</td>
|
3898
3898
|
<td>
|
3899
|
-
<pre id="exp_387"
|
3899
|
+
<pre id="exp_387">After insertion sort:</pre>
|
3900
3900
|
</td>
|
3901
3901
|
</tr>
|
3902
3902
|
|
@@ -3906,7 +3906,7 @@
|
|
3906
3906
|
<pre id="out_388"></pre>
|
3907
3907
|
</td>
|
3908
3908
|
<td>
|
3909
|
-
<pre id="exp_388">
|
3909
|
+
<pre id="exp_388">[1, 2, 3, 3, 5, 6, 7, 8]</pre>
|
3910
3910
|
</td>
|
3911
3911
|
</tr>
|
3912
3912
|
|
@@ -3916,7 +3916,7 @@
|
|
3916
3916
|
<pre id="out_389"></pre>
|
3917
3917
|
</td>
|
3918
3918
|
<td>
|
3919
|
-
<pre id="exp_389"
|
3919
|
+
<pre id="exp_389">Array args</pre>
|
3920
3920
|
</td>
|
3921
3921
|
</tr>
|
3922
3922
|
|
@@ -3926,7 +3926,7 @@
|
|
3926
3926
|
<pre id="out_390"></pre>
|
3927
3927
|
</td>
|
3928
3928
|
<td>
|
3929
|
-
<pre id="exp_390">
|
3929
|
+
<pre id="exp_390">Hello World !</pre>
|
3930
3930
|
</td>
|
3931
3931
|
</tr>
|
3932
3932
|
|
@@ -3936,7 +3936,7 @@
|
|
3936
3936
|
<pre id="out_391"></pre>
|
3937
3937
|
</td>
|
3938
3938
|
<td>
|
3939
|
-
<pre id="exp_391">
|
3939
|
+
<pre id="exp_391">Block</pre>
|
3940
3940
|
</td>
|
3941
3941
|
</tr>
|
3942
3942
|
|
@@ -3946,114 +3946,404 @@
|
|
3946
3946
|
<pre id="out_392"></pre>
|
3947
3947
|
</td>
|
3948
3948
|
<td>
|
3949
|
-
<pre id="exp_392"
|
3949
|
+
<pre id="exp_392">Action is eloquence - William Shakespeare</pre>
|
3950
3950
|
</td>
|
3951
3951
|
</tr>
|
3952
3952
|
|
3953
3953
|
|
3954
|
-
<tr
|
3955
|
-
|
3956
|
-
<tr id="line_393">
|
3954
|
+
<tr id="line_393" style="background: #ff8888">
|
3957
3955
|
<td>
|
3958
3956
|
<pre id="out_393"></pre>
|
3959
3957
|
</td>
|
3960
3958
|
<td>
|
3961
|
-
<pre id="exp_393"
|
3959
|
+
<pre id="exp_393">Class</pre>
|
3962
3960
|
</td>
|
3963
3961
|
</tr>
|
3964
3962
|
|
3965
3963
|
|
3966
|
-
<tr id="line_394">
|
3964
|
+
<tr id="line_394" style="background: #ff8888">
|
3967
3965
|
<td>
|
3968
3966
|
<pre id="out_394"></pre>
|
3969
3967
|
</td>
|
3970
3968
|
<td>
|
3971
|
-
<pre id="exp_394"
|
3969
|
+
<pre id="exp_394">PI is about</pre>
|
3972
3970
|
</td>
|
3973
3971
|
</tr>
|
3974
3972
|
|
3975
3973
|
|
3976
|
-
<tr id="line_395">
|
3974
|
+
<tr id="line_395" style="background: #ff8888">
|
3977
3975
|
<td>
|
3978
3976
|
<pre id="out_395"></pre>
|
3979
3977
|
</td>
|
3980
3978
|
<td>
|
3981
|
-
<pre id="exp_395"
|
3979
|
+
<pre id="exp_395">3.14159292035</pre>
|
3982
3980
|
</td>
|
3983
3981
|
</tr>
|
3984
3982
|
|
3985
3983
|
|
3986
|
-
<tr id="line_396">
|
3984
|
+
<tr id="line_396" style="background: #ff8888">
|
3987
3985
|
<td>
|
3988
3986
|
<pre id="out_396"></pre>
|
3989
3987
|
</td>
|
3990
3988
|
<td>
|
3991
|
-
<pre id="exp_396"
|
3989
|
+
<pre id="exp_396">Const</pre>
|
3992
3990
|
</td>
|
3993
3991
|
</tr>
|
3994
3992
|
|
3995
3993
|
|
3996
|
-
<tr id="line_397">
|
3994
|
+
<tr id="line_397" style="background: #ff8888">
|
3997
3995
|
<td>
|
3998
3996
|
<pre id="out_397"></pre>
|
3999
3997
|
</td>
|
4000
3998
|
<td>
|
4001
|
-
<pre id="exp_397"
|
3999
|
+
<pre id="exp_397">~~~~~~~~~~~~~~~~~~~~</pre>
|
4002
4000
|
</td>
|
4003
4001
|
</tr>
|
4004
4002
|
|
4005
4003
|
|
4006
|
-
<tr id="line_398">
|
4004
|
+
<tr id="line_398" style="background: #ff8888">
|
4007
4005
|
<td>
|
4008
4006
|
<pre id="out_398"></pre>
|
4009
4007
|
</td>
|
4010
4008
|
<td>
|
4011
|
-
<pre id="exp_398"
|
4009
|
+
<pre id="exp_398">Test new</pre>
|
4012
4010
|
</td>
|
4013
4011
|
</tr>
|
4014
4012
|
|
4015
4013
|
|
4016
|
-
<tr id="line_399">
|
4014
|
+
<tr id="line_399" style="background: #ff8888">
|
4017
4015
|
<td>
|
4018
4016
|
<pre id="out_399"></pre>
|
4019
4017
|
</td>
|
4020
4018
|
<td>
|
4021
|
-
<pre id="exp_399"
|
4019
|
+
<pre id="exp_399">~~~~~~~~~~~~~~~~~~~~</pre>
|
4022
4020
|
</td>
|
4023
4021
|
</tr>
|
4024
4022
|
|
4025
4023
|
|
4026
|
-
<tr id="line_400">
|
4024
|
+
<tr id="line_400" style="background: #ff8888">
|
4027
4025
|
<td>
|
4028
4026
|
<pre id="out_400"></pre>
|
4029
4027
|
</td>
|
4030
4028
|
<td>
|
4031
|
-
<pre id="exp_400"
|
4029
|
+
<pre id="exp_400">test</pre>
|
4032
4030
|
</td>
|
4033
4031
|
</tr>
|
4034
4032
|
|
4035
4033
|
|
4036
|
-
<tr id="line_401">
|
4034
|
+
<tr id="line_401" style="background: #ff8888">
|
4037
4035
|
<td>
|
4038
4036
|
<pre id="out_401"></pre>
|
4039
4037
|
</td>
|
4040
4038
|
<td>
|
4041
|
-
<pre id="exp_401"
|
4039
|
+
<pre id="exp_401">~~~~~~~~~~~~~~~~~~~~</pre>
|
4042
4040
|
</td>
|
4043
4041
|
</tr>
|
4044
4042
|
|
4045
4043
|
|
4046
|
-
<tr id="line_402">
|
4044
|
+
<tr id="line_402" style="background: #ff8888">
|
4047
4045
|
<td>
|
4048
4046
|
<pre id="out_402"></pre>
|
4049
4047
|
</td>
|
4050
4048
|
<td>
|
4051
|
-
<pre id="exp_402"
|
4049
|
+
<pre id="exp_402">Test exception</pre>
|
4050
|
+
</td>
|
4051
|
+
</tr>
|
4052
|
+
|
4053
|
+
|
4054
|
+
<tr id="line_403" style="background: #ff8888">
|
4055
|
+
<td>
|
4056
|
+
<pre id="out_403"></pre>
|
4057
|
+
</td>
|
4058
|
+
<td>
|
4059
|
+
<pre id="exp_403">~~~~~~~~~~~~~~~~~~~~</pre>
|
4060
|
+
</td>
|
4061
|
+
</tr>
|
4062
|
+
|
4063
|
+
|
4064
|
+
<tr id="line_404" style="background: #ff8888">
|
4065
|
+
<td>
|
4066
|
+
<pre id="out_404"></pre>
|
4067
|
+
</td>
|
4068
|
+
<td>
|
4069
|
+
<pre id="exp_404">"before block"</pre>
|
4070
|
+
</td>
|
4071
|
+
</tr>
|
4072
|
+
|
4073
|
+
|
4074
|
+
<tr id="line_405" style="background: #ff8888">
|
4075
|
+
<td>
|
4076
|
+
<pre id="out_405"></pre>
|
4077
|
+
</td>
|
4078
|
+
<td>
|
4079
|
+
<pre id="exp_405">"in block"</pre>
|
4080
|
+
</td>
|
4081
|
+
</tr>
|
4082
|
+
|
4083
|
+
|
4084
|
+
<tr id="line_406" style="background: #ff8888">
|
4085
|
+
<td>
|
4086
|
+
<pre id="out_406"></pre>
|
4087
|
+
</td>
|
4088
|
+
<td>
|
4089
|
+
<pre id="exp_406">"after block"</pre>
|
4090
|
+
</td>
|
4091
|
+
</tr>
|
4092
|
+
|
4093
|
+
|
4094
|
+
<tr id="line_407" style="background: #ff8888">
|
4095
|
+
<td>
|
4096
|
+
<pre id="out_407"></pre>
|
4097
|
+
</td>
|
4098
|
+
<td>
|
4099
|
+
<pre id="exp_407">"block"</pre>
|
4100
|
+
</td>
|
4101
|
+
</tr>
|
4102
|
+
|
4103
|
+
|
4104
|
+
<tr id="line_408" style="background: #ff8888">
|
4105
|
+
<td>
|
4106
|
+
<pre id="out_408"></pre>
|
4107
|
+
</td>
|
4108
|
+
<td>
|
4109
|
+
<pre id="exp_408">"else"</pre>
|
4110
|
+
</td>
|
4111
|
+
</tr>
|
4112
|
+
|
4113
|
+
|
4114
|
+
<tr id="line_409" style="background: #ff8888">
|
4115
|
+
<td>
|
4116
|
+
<pre id="out_409"></pre>
|
4117
|
+
</td>
|
4118
|
+
<td>
|
4119
|
+
<pre id="exp_409">#<RuntimeError: test></pre>
|
4120
|
+
</td>
|
4121
|
+
</tr>
|
4122
|
+
|
4123
|
+
|
4124
|
+
<tr id="line_410" style="background: #ff8888">
|
4125
|
+
<td>
|
4126
|
+
<pre id="out_410"></pre>
|
4127
|
+
</td>
|
4128
|
+
<td>
|
4129
|
+
<pre id="exp_410">before begin</pre>
|
4130
|
+
</td>
|
4131
|
+
</tr>
|
4132
|
+
|
4133
|
+
|
4134
|
+
<tr id="line_411" style="background: #ff8888">
|
4135
|
+
<td>
|
4136
|
+
<pre id="out_411"></pre>
|
4137
|
+
</td>
|
4138
|
+
<td>
|
4139
|
+
<pre id="exp_411">before raise</pre>
|
4140
|
+
</td>
|
4141
|
+
</tr>
|
4142
|
+
|
4143
|
+
|
4144
|
+
<tr id="line_412" style="background: #ff8888">
|
4145
|
+
<td>
|
4146
|
+
<pre id="out_412"></pre>
|
4147
|
+
</td>
|
4148
|
+
<td>
|
4149
|
+
<pre id="exp_412">#<Exception: blah></pre>
|
4150
|
+
</td>
|
4151
|
+
</tr>
|
4152
|
+
|
4153
|
+
|
4154
|
+
<tr id="line_413" style="background: #ff8888">
|
4155
|
+
<td>
|
4156
|
+
<pre id="out_413"></pre>
|
4157
|
+
</td>
|
4158
|
+
<td>
|
4159
|
+
<pre id="exp_413">yes</pre>
|
4160
|
+
</td>
|
4161
|
+
</tr>
|
4162
|
+
|
4163
|
+
|
4164
|
+
<tr id="line_414" style="background: #ff8888">
|
4165
|
+
<td>
|
4166
|
+
<pre id="out_414"></pre>
|
4167
|
+
</td>
|
4168
|
+
<td>
|
4169
|
+
<pre id="exp_414">ensure</pre>
|
4170
|
+
</td>
|
4171
|
+
</tr>
|
4172
|
+
|
4173
|
+
|
4174
|
+
<tr id="line_415" style="background: #ff8888">
|
4175
|
+
<td>
|
4176
|
+
<pre id="out_415"></pre>
|
4177
|
+
</td>
|
4178
|
+
<td>
|
4179
|
+
<pre id="exp_415">after begin</pre>
|
4180
|
+
</td>
|
4181
|
+
</tr>
|
4182
|
+
|
4183
|
+
|
4184
|
+
<tr id="line_416" style="background: #ff8888">
|
4185
|
+
<td>
|
4186
|
+
<pre id="out_416"></pre>
|
4187
|
+
</td>
|
4188
|
+
<td>
|
4189
|
+
<pre id="exp_416">--</pre>
|
4190
|
+
</td>
|
4191
|
+
</tr>
|
4192
|
+
|
4193
|
+
|
4194
|
+
<tr id="line_417" style="background: #ff8888">
|
4195
|
+
<td>
|
4196
|
+
<pre id="out_417"></pre>
|
4197
|
+
</td>
|
4198
|
+
<td>
|
4199
|
+
<pre id="exp_417">abc</pre>
|
4200
|
+
</td>
|
4201
|
+
</tr>
|
4202
|
+
|
4203
|
+
|
4204
|
+
<tr id="line_418" style="background: #ff8888">
|
4205
|
+
<td>
|
4206
|
+
<pre id="out_418"></pre>
|
4207
|
+
</td>
|
4208
|
+
<td>
|
4209
|
+
<pre id="exp_418">#<RuntimeError: r></pre>
|
4210
|
+
</td>
|
4211
|
+
</tr>
|
4212
|
+
|
4213
|
+
|
4214
|
+
<tr id="line_419" style="background: #ff8888">
|
4215
|
+
<td>
|
4216
|
+
<pre id="out_419"></pre>
|
4217
|
+
</td>
|
4218
|
+
<td>
|
4219
|
+
<pre id="exp_419">b</pre>
|
4220
|
+
</td>
|
4221
|
+
</tr>
|
4222
|
+
|
4223
|
+
|
4224
|
+
<tr id="line_420" style="background: #ff8888">
|
4225
|
+
<td>
|
4226
|
+
<pre id="out_420"></pre>
|
4227
|
+
</td>
|
4228
|
+
<td>
|
4229
|
+
<pre id="exp_420">e</pre>
|
4230
|
+
</td>
|
4231
|
+
</tr>
|
4232
|
+
|
4233
|
+
|
4234
|
+
<tr id="line_421" style="background: #ff8888">
|
4235
|
+
<td>
|
4236
|
+
<pre id="out_421"></pre>
|
4237
|
+
</td>
|
4238
|
+
<td>
|
4239
|
+
<pre id="exp_421">#<ArgumentError: wrong number of arguments (1 for 0)></pre>
|
4240
|
+
</td>
|
4241
|
+
</tr>
|
4242
|
+
|
4243
|
+
|
4244
|
+
<tr><td colspan="2" style="background: grey"> </td></tr>
|
4245
|
+
|
4246
|
+
<tr id="line_422">
|
4247
|
+
<td>
|
4248
|
+
<pre id="out_422"></pre>
|
4249
|
+
</td>
|
4250
|
+
<td>
|
4251
|
+
<pre id="exp_422"></pre>
|
4252
|
+
</td>
|
4253
|
+
</tr>
|
4254
|
+
|
4255
|
+
|
4256
|
+
<tr id="line_423">
|
4257
|
+
<td>
|
4258
|
+
<pre id="out_423"></pre>
|
4259
|
+
</td>
|
4260
|
+
<td>
|
4261
|
+
<pre id="exp_423"></pre>
|
4262
|
+
</td>
|
4263
|
+
</tr>
|
4264
|
+
|
4265
|
+
|
4266
|
+
<tr id="line_424">
|
4267
|
+
<td>
|
4268
|
+
<pre id="out_424"></pre>
|
4269
|
+
</td>
|
4270
|
+
<td>
|
4271
|
+
<pre id="exp_424"></pre>
|
4272
|
+
</td>
|
4273
|
+
</tr>
|
4274
|
+
|
4275
|
+
|
4276
|
+
<tr id="line_425">
|
4277
|
+
<td>
|
4278
|
+
<pre id="out_425"></pre>
|
4279
|
+
</td>
|
4280
|
+
<td>
|
4281
|
+
<pre id="exp_425"></pre>
|
4282
|
+
</td>
|
4283
|
+
</tr>
|
4284
|
+
|
4285
|
+
|
4286
|
+
<tr id="line_426">
|
4287
|
+
<td>
|
4288
|
+
<pre id="out_426"></pre>
|
4289
|
+
</td>
|
4290
|
+
<td>
|
4291
|
+
<pre id="exp_426"></pre>
|
4292
|
+
</td>
|
4293
|
+
</tr>
|
4294
|
+
|
4295
|
+
|
4296
|
+
<tr id="line_427">
|
4297
|
+
<td>
|
4298
|
+
<pre id="out_427"></pre>
|
4299
|
+
</td>
|
4300
|
+
<td>
|
4301
|
+
<pre id="exp_427"></pre>
|
4302
|
+
</td>
|
4303
|
+
</tr>
|
4304
|
+
|
4305
|
+
|
4306
|
+
<tr id="line_428">
|
4307
|
+
<td>
|
4308
|
+
<pre id="out_428"></pre>
|
4309
|
+
</td>
|
4310
|
+
<td>
|
4311
|
+
<pre id="exp_428"></pre>
|
4312
|
+
</td>
|
4313
|
+
</tr>
|
4314
|
+
|
4315
|
+
|
4316
|
+
<tr id="line_429">
|
4317
|
+
<td>
|
4318
|
+
<pre id="out_429"></pre>
|
4319
|
+
</td>
|
4320
|
+
<td>
|
4321
|
+
<pre id="exp_429"></pre>
|
4322
|
+
</td>
|
4323
|
+
</tr>
|
4324
|
+
|
4325
|
+
|
4326
|
+
<tr id="line_430">
|
4327
|
+
<td>
|
4328
|
+
<pre id="out_430"></pre>
|
4329
|
+
</td>
|
4330
|
+
<td>
|
4331
|
+
<pre id="exp_430"></pre>
|
4332
|
+
</td>
|
4333
|
+
</tr>
|
4334
|
+
|
4335
|
+
|
4336
|
+
<tr id="line_431">
|
4337
|
+
<td>
|
4338
|
+
<pre id="out_431"></pre>
|
4339
|
+
</td>
|
4340
|
+
<td>
|
4341
|
+
<pre id="exp_431"></pre>
|
4052
4342
|
</td>
|
4053
4343
|
</tr>
|
4054
4344
|
|
4055
4345
|
|
4056
4346
|
</tbody>
|
4057
4347
|
</table>
|
4058
|
-
<pre id="source">require 'common'<br/><br/>#<br/># file: test/test_hash.rb<br/>#<br/><br/>module T_TestHash<br/>class TestHash<br/> if $RUBYJS<br/> def hash<br/> `var el = {}; el["1"] = null; return el`<br/> end<br/> else<br/> def hash<br/> {"1" => nil}<br/> end<br/> end<br/><br/> def test<br/> h = {"a" => 6, "b" => 7, "1" => 1, 1 => 2, "1,2" => "hello", [1,2] => "good"} <br/> p h["a"]<br/> p h["b"] <br/> p h["1"]<br/> p h[1]<br/> p h["1,2"]<br/> p h[[1,2]] <br/><br/> puts "test native JS hash"<br/> a = hash()<br/> #p a<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_yield.rb<br/>#<br/><br/>module T_TestYield<br/>class TestYield<br/> def three_times_yield<br/> yield 1<br/> yield 2<br/> yield 3<br/> end<br/><br/> def test_three_times_yield<br/> puts "three_times_yield"<br/> three_times_yield {|i| p i }<br/> puts "--"<br/> end<br/><br/> def three_times_block(&block)<br/> block.call(1)<br/> block.call(2)<br/> block.call(3)<br/> end<br/><br/> def test_three_times_block<br/> puts "three_times_block"<br/> three_times_block {|i| p i }<br/> puts "--"<br/> end<br/><br/> def three_times_indirect(&block)<br/> three_times_yield(&block) <br/> three_times_block(&block) <br/> end<br/><br/> def test_three_times_indirect<br/> puts "three_times_indirect"<br/> three_times_indirect {|i| p i}<br/> puts "--"<br/> end<br/><br/> def three_times_yield2<br/> p yield(1)<br/> p yield(2)<br/> p yield(3)<br/> end<br/><br/> def test_three_times_yield2<br/> puts "three_times_yield2"<br/> three_times_yield2 {|i|<br/> if i == 1<br/> i<br/> else<br/> next i+1<br/> end<br/> }<br/> end<br/><br/> def loop<br/> while true<br/> yield<br/> end<br/> p "not reached"<br/> end<br/><br/> def loop2(&block)<br/> while true<br/> block.call<br/> end<br/> p "not reached"<br/> end<br/><br/> def test_loop<br/> puts "loop"<br/> i = 0 <br/> res = loop do <br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break "out", i if i > 8<br/> end <br/> p res<br/> puts "--"<br/> end<br/><br/> def test_loop2<br/> puts "loop2"<br/> i = 0 <br/> res = loop2 do <br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break "out", i if i > 8<br/> end <br/> p res<br/> puts "--"<br/> end<br/><br/> def test_while_loop<br/> puts "while-loop"<br/> i = 0 <br/> while true<br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break if i > 8<br/> end<br/> puts "----"<br/> while i > 0<br/> p i<br/> i -= 1<br/> end<br/> puts "--"<br/> end<br/><br/> def return_in_block(&block)<br/> p "return_in_block before"<br/> block.call<br/> p "return_in_block after"<br/> end<br/><br/> def test_return_in_block<br/> p "before"<br/> return_in_block { return 4 }<br/> p "after (NOT)"<br/> end<br/><br/> def test_proc<br/> p "test_proc"<br/> a = proc { return 0 }<br/> p a.call<br/> a = Proc.new { break 3 }<br/> p a.call<br/> end<br/><br/> def test<br/> test_three_times_yield<br/> test_three_times_block<br/> test_three_times_indirect<br/> test_three_times_yield2<br/> test_loop<br/> test_loop2<br/> test_while_loop<br/><br/> begin<br/> test_proc<br/> rescue LocalJumpError => e<br/> p e<br/> end<br/><br/> p test_return_in_block()<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_lebewesen.rb<br/>#<br/><br/>module T_TestLebewesen<br/>class TestLebewesen<br/> def self.main<br/> leni = Katze.new("AA-BB", "Leni")<br/> flocki = Katze.new("AC-DC", "Flocki") <br/> bello = Hund.new("AA-ZZ")<br/> leni.miau<br/> bello.wau<br/> bello.jage(leni)<br/> end<br/>end<br/><br/>class Lebewesen<br/> def initialize(dns)<br/> @dns = dns<br/> end<br/>end<br/><br/>class Katze < Lebewesen<br/> attr_reader :name<br/><br/> def initialize(dns, name)<br/> super(dns)<br/> @name = name<br/> end<br/><br/> def miau<br/> puts "miau, ich bin " + @name<br/> end<br/>end<br/><br/>class Hund < Lebewesen<br/> def wau<br/> puts "wau wau"<br/> end<br/><br/> def jage(katze)<br/> puts "ich jage " + katze.name<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_expr.rb<br/>#<br/><br/>module T_TestExpr<br/>class TestExpr<br/> def test<br/> i = if true then 1 else 2 end<br/> p i<br/> i = true or return<br/> p i<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_simple_output.rb<br/>#<br/><br/>module T_TestSimpleOutput<br/>class TestSimpleOutput <br/> def self.main()<br/> puts "Hello World from RubyJS"<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_if.rb<br/>#<br/><br/>module T_TestIf<br/>class TestIf<br/> def test<br/> puts "OK" if true<br/> puts "NOT OK" if false<br/> puts "OK" unless false<br/> puts "NOT OK" unless true<br/> puts "OK" if true and true and (true or false) and (!false)<br/><br/> puts "OK" if 5 < 6 and 6 < 7<br/><br/> # test the "||" operator<br/> p(false || "a") # => "a"<br/> p(nil || "a") # => "a"<br/> p(true || "a") # => true<br/> p("b" || "a") # => "b"<br/><br/> # test the "&&" operator<br/><br/> p(false && "a") # => false<br/> p(nil && "a") # => nil<br/> p(true && "a") # => "a"<br/> p("b" && "a") # => "a"<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_class.rb<br/>#<br/><br/>module T_TestClass<br/>module X<br/>end<br/><br/>class A<br/> include X<br/>end<br/><br/>class B < A<br/>end<br/><br/>class C < B<br/>end<br/><br/>class D<br/>end<br/><br/>class TestClass<br/> def self.main<br/> p A.new.instance_of?(A) # => true<br/> p A.new.instance_of?(B) # => false<br/> p B.new.instance_of?(A) # => false<br/> p A.new.instance_of?(X) # => false<br/> p B.new.instance_of?(X) # => false<br/><br/> p A.new.kind_of?(A) # => true<br/> p A.new.kind_of?(B) # => false<br/> p B.new.kind_of?(A) # => true<br/> p A.new.kind_of?(X) # => true<br/> p B.new.kind_of?(X) # => true<br/><br/> p C.new.kind_of?(X) # => true<br/> p C.new.kind_of?(A) # => true<br/> p C.new.kind_of?(B) # => true<br/> p C.new.kind_of?(C) # => true<br/> p C.new.kind_of?(D) # => false<br/> p C.new.kind_of?(Object) # => true<br/> p C.new.kind_of?(Kernel) # => true<br/> p C.new.kind_of?(Class) # => false<br/><br/> p ("hallo".class.name)<br/> p (nil.class.name)<br/> p (nil.instance_of?(NilClass))<br/> p ("hallo".instance_of?(String))<br/> p ("hallo".class)<br/> p A<br/> p B<br/> p C<br/> p D<br/> p X<br/><br/> p X.name<br/> p A.name<br/> p B.name<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_case.rb<br/>#<br/><br/>module T_TestCase<br/>class TestCase<br/> def test<br/> case 1+1<br/> when 1, 3<br/> puts "NOT OKAY"<br/> when 2<br/> puts "OKAY"<br/> else<br/> puts "NOT OKAY"<br/> end<br/><br/> p (Array === [])<br/> p (RuntimeError === RuntimeError.new)<br/><br/> case 1<br/> when Fixnum <br/> puts "OK"<br/> when 1<br/> puts "OK"<br/> end<br/><br/> case 4<br/> when 0..3<br/> puts "NOT OKAY"<br/> when 1...4<br/> puts "NOT OKAY"<br/> when 2..4<br/> puts "OKAY"<br/> end<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_splat.rb<br/>#<br/><br/>module T_TestSplat<br/>class TestSplat<br/> def m(*args)<br/> p args<br/> end<br/><br/> def self.main<br/> obj = new()<br/><br/> obj.m<br/> obj.m(*[])<br/><br/> obj.m(1)<br/> obj.m(*[1])<br/> obj.m(1,*[])<br/><br/> obj.m(1,2)<br/> obj.m(*[1,2])<br/> obj.m(1,*[2])<br/> obj.m(1,*[1,2])<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_string.rb<br/>#<br/><br/>module T_TestString<br/>class TestString<br/> def test<br/> # inspect<br/> p "hello"<br/> p "hallo\b\t\n"<br/> p "hallo\\leute"<br/> p '"super"'<br/> <br/> # index<br/> p "hello".index('e')<br/> p "hello".index('lo')<br/> p "hello".index('a')<br/> p "hello hello".index('ll')<br/> p "hello hello".index('ll', 3)<br/><br/> # []<br/> p "hallo"[0,1]<br/> p "hallo"[0,2]<br/> p "hallo"[0,5]<br/><br/> p ("10".rjust(10, "0"))<br/> p ("10".rjust(1, "blah"))<br/> p ("x".rjust(4, "()"))<br/><br/> p ("10".ljust(10, "0"))<br/> p ("10".ljust(1, "blah"))<br/> p ("x".ljust(4, "()"))<br/><br/><br/> # string interpolation<br/> p "abc #{ 1 + 2 } def"<br/> @a = "hallo".inspect<br/> @b = 4.5<br/> p "#{@a},#{@b}"<br/><br/> # gsub<br/> s = "hallo".gsub("l", "r")<br/> p s<br/> s = "hallo".gsub(/ll/, "rr")<br/> p s<br/> s = "hallo".gsub(/l/) { "r" }<br/> p s<br/> s = "hallo".gsub(/ll/) { "blah blah" }<br/> p s<br/> "hallllllo".gsub(/(l)l/) {|i| p i }<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_inspect.rb<br/>#<br/><br/>module T_TestInspect<br/>class TestInspect<br/> def test<br/> o = [{"Hello"=>'Rubyconf'}]<br/> puts o.inspect<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_regexp.rb<br/>#<br/><br/>module T_TestRegexp<br/>class TestRegexp<br/> def test<br/> p "okay" if "hallo" =~ /ll/<br/> pos = "hallo" =~ /ll/<br/> p pos<br/><br/> "hallo" =~ /(ll)/<br/> p $1<br/> p $2<br/> p $3<br/><br/> "hallo" =~ /a(ll)(o)/<br/> p $1<br/> p $2<br/> p $3<br/> p $4<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_args.rb<br/>#<br/><br/>module T_TestArgs<br/>class TestArgs<br/> def m(a, b=1, c="hallo", *args) <br/> p a<br/> p b<br/> p c<br/> p args<br/> end<br/><br/> def self.main<br/> obj = new()<br/><br/> obj.m(0)<br/> puts "--"<br/> obj.m(1,2)<br/> puts "--"<br/> obj.m(1,2,9)<br/> puts "--"<br/> obj.m(1,2,9,5)<br/> puts "--"<br/> obj.m(1,2,9,5,6)<br/> puts "--"<br/> obj.m(1,2,9,5,6,7,8,9,10,11,12)<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_array.rb<br/>#<br/><br/>module T_TestArray<br/>class TestArray<br/> if $RUBYJS<br/> def array<br/> [1, 2, `null`, [`null`, `null`, 4]]<br/> end<br/> else<br/> def array<br/> [1, 2, nil, [nil, nil, 4]]<br/> end<br/> end<br/><br/> def test<br/> # delete<br/> a = [ "a", "b", "b", "b", "c" ]<br/> p a.delete("b") #=> "b"<br/> p a #=> ["a", "c"]<br/> p a.delete("z") #=> nil<br/><br/> puts "test native JS array mapping"<br/> p array()<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_eql.rb<br/>#<br/><br/>module T_TestEql<br/>class TestEql<br/> def self.main<br/> p "a".eql?("a") # => true<br/> p "a".eql?(1) # => false<br/> p "1".eql?(1) # => false<br/> p [1,2].eql?([1,2]) # => true<br/> p 1.eql?("1") # => false<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_send.rb<br/>#<br/><br/>module T_TestSend<br/>class A<br/> def a_method(a,b)<br/> p a, b<br/> end<br/>end<br/><br/>class B < A<br/> def a_method(b, a)<br/> p "in B"<br/> super<br/> end<br/><br/> def c_method(b)<br/> end<br/>end<br/><br/>class C<br/> def method_missing(id, *args, &block)<br/> p "mm: #{id}, #{args}"<br/> end<br/>end<br/><br/>class TestSend<br/> def self.main<br/> puts "send"<br/> p A.new.send("a_method", 1, 2)<br/> p B.new.send("a_method", 1, 2)<br/><br/> puts "respond_to?"<br/> p A.new.respond_to?(:a_method)<br/> p A.new.respond_to?(:to_s)<br/> p A.new.respond_to?(:inspect)<br/> p A.new.respond_to?(:b_method)<br/> p A.new.respond_to?(:c_method)<br/><br/> puts "method_missing"<br/> p C.new.respond_to?(:blah_blah)<br/> C.new.blah_blah(1,2,3)<br/><br/> begin<br/> A.new.blah_blah<br/> puts "FAILURE?"<br/> rescue NoMethodError<br/> puts "catched!!!"<br/> end<br/><br/> begin<br/> A.not_a_method<br/> rescue NoMethodError<br/> p "goood"<br/> end<br/><br/> puts "class Method"<br/> m = "hallo".method(:to_s)<br/> p m<br/> p m.call<br/><br/> a = [1,2,3]<br/> m = a.method(:+)<br/> p m<br/> p m.call([2,3])<br/> p m<br/> p a<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_range.rb<br/>#<br/><br/>module T_TestRange<br/>class TestRange<br/> def test<br/> a = Range.new(0,2)<br/> p a.first<br/> p a.last<br/> p a<br/><br/> p ((0..2).to_s)<br/> p ((0...2).to_s)<br/><br/> (0..4).each do |i| p i end<br/> (0...4).each do |i| p i end<br/> (-1..-4).each do |i| p i end<br/><br/> p ((0..4).include?(4))<br/> p ((0..4).include?(5))<br/> p ((0...4).include?(5))<br/> p ((0...4).include?(4))<br/> p ((0...4).include?(3))<br/> p ((0...4).include?(0))<br/> p ((0...4).include?(-1))<br/><br/> p ((-1..-5).to_a)<br/> p ((-5..-1).to_a)<br/><br/> r = Range.new(0, 4)<br/> p r.first<br/> p r.begin<br/> p r.last<br/> p r.end<br/> p r.exclude_end?<br/><br/> r = 1...5<br/> p r.first<br/> p r.begin<br/> p r.last<br/> p r.end<br/> p r.exclude_end?<br/><br/> p (false == false)<br/> p (false == true)<br/> p (true == false)<br/> p (true == true)<br/><br/> p ((0..2) == (0..2))<br/> p ((0..2) == Range.new(0,2))<br/> p ((0..2) == (0...2))<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_massign.rb<br/>#<br/><br/>module T_TestMassign<br/>class TestMassign<br/> def self.main<br/> a, b = 1, 2<br/> p a<br/> p b<br/> puts "--"<br/><br/> a, b = 1, 2, 3<br/> p a<br/> p b<br/> puts "--"<br/><br/> c = 5<br/> a, b, c = 1, 2 <br/> p a<br/> p b<br/> p c<br/> puts "--"<br/><br/> @a, b, @c = 1, 2, 3<br/> p @a<br/> p b<br/> p @c<br/> puts "--"<br/><br/> puts "swap"<br/> # swap<br/> a, b = 1, 2<br/> p a<br/> p b<br/> a, b = b, a<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat1"<br/> a, b, c, *d = 1, 2 <br/> p a<br/> p b<br/> p c<br/> p d<br/> puts "--"<br/><br/> puts "splat2"<br/> a, *b = 1, 2<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat3"<br/> a, *b = 1, 2, 3, 4, 5<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat with globals"<br/> p $a<br/> p $b<br/> $a, $b = 1, 2 <br/> p $a<br/> p $b<br/> puts "--"<br/> <br/> #TODO: a, b = 1 (to_ary)<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_new.rb<br/>#<br/><br/>module T_TestNew<br/>class TestNew<br/> def initialize<br/> end<br/><br/> def test<br/> puts "test"<br/> end<br/><br/> def self.main()<br/> new().test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_exception.rb<br/>#<br/><br/>module T_TestException<br/>class TestException<br/> def self.main<br/><br/> p "before block"<br/> begin<br/> p "in block"<br/> end<br/> p "after block"<br/><br/> ###<br/> begin<br/> p "block"<br/> rescue<br/> p "rescue"<br/> rescue Exception => a<br/> p "another rescue"<br/> p a<br/> else<br/> p "else"<br/> end<br/><br/> p RuntimeError.new("test")<br/><br/> puts "before begin"<br/> begin<br/> puts "before raise"<br/> raise Exception, "blah" <br/> puts "after raise"<br/> rescue<br/> puts "noooo"<br/> rescue Exception => a<br/> p a<br/> puts "yes"<br/> ensure<br/> puts "ensure"<br/> end<br/> puts "after begin"<br/><br/> puts "--"<br/><br/> begin<br/> puts "abc"<br/> raise "r"<br/> rescue<br/> p $!<br/> puts "b"<br/> ensure<br/> puts "e"<br/> end<br/><br/> #<br/> # Test arity checks<br/> #<br/><br/> begin<br/> p("hallo".to_s(2))<br/> rescue ArgumentError => a<br/> p a<br/> end<br/> end<br/>end<br/>end<br/><br/><br/><br/> class TestSuite<br/> def self.main<br/> begin<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test hash'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestHash::TestHash.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test yield'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestYield::TestYield.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test lebewesen'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestLebewesen::TestLebewesen.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test expr'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestExpr::TestExpr.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test simple output'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSimpleOutput::TestSimpleOutput.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test if'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestIf::TestIf.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test class'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestClass::TestClass.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test case'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestCase::TestCase.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test splat'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSplat::TestSplat.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test string'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestString::TestString.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test inspect'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestInspect::TestInspect.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test regexp'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestRegexp::TestRegexp.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test args'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestArgs::TestArgs.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test array'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestArray::TestArray.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test eql'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestEql::TestEql.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test send'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSend::TestSend.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test range'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestRange::TestRange.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test massign'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestMassign::TestMassign.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test new'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestNew::TestNew.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test exception'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestException::TestException.main<br/> <br/> rescue Exception => a<br/> p "unhandled exception"<br/> p a<br/> end<br/> end<br/> end<br/> TestSuite.main unless $RUBYJS<br/> </pre>
|
4348
|
+
<pre id="source">require 'common'<br/><br/>#<br/># file: test/test_hash.rb<br/>#<br/><br/>module T_TestHash<br/>class TestHash<br/> if $RUBYJS<br/> def hash<br/> `var el = {}; el["1"] = null; return el`<br/> end<br/> else<br/> def hash<br/> {"1" => nil}<br/> end<br/> end<br/><br/> def test<br/> h = {"a" => 6, "b" => 7, "1" => 1, 1 => 2, "1,2" => "hello", [1,2] => "good"} <br/> p h["a"]<br/> p h["b"] <br/> p h["1"]<br/> p h[1]<br/> p h["1,2"]<br/> p h[[1,2]] <br/><br/> puts "test native JS hash"<br/> a = hash()<br/> #p a<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_yield.rb<br/>#<br/><br/>module T_TestYield<br/>class TestYield<br/> def three_times_yield<br/> yield 1<br/> yield 2<br/> yield 3<br/> end<br/><br/> def test_three_times_yield<br/> puts "three_times_yield"<br/> three_times_yield {|i| p i }<br/> puts "--"<br/> end<br/><br/> def three_times_block(&block)<br/> block.call(1)<br/> block.call(2)<br/> block.call(3)<br/> end<br/><br/> def test_three_times_block<br/> puts "three_times_block"<br/> three_times_block {|i| p i }<br/> puts "--"<br/> end<br/><br/> def three_times_indirect(&block)<br/> three_times_yield(&block) <br/> three_times_block(&block) <br/> end<br/><br/> def test_three_times_indirect<br/> puts "three_times_indirect"<br/> three_times_indirect {|i| p i}<br/> puts "--"<br/> end<br/><br/> def three_times_yield2<br/> p yield(1)<br/> p yield(2)<br/> p yield(3)<br/> end<br/><br/> def test_three_times_yield2<br/> puts "three_times_yield2"<br/> three_times_yield2 {|i|<br/> if i == 1<br/> i<br/> else<br/> next i+1<br/> end<br/> }<br/> end<br/><br/> def loop<br/> while true<br/> yield<br/> end<br/> p "not reached"<br/> end<br/><br/> def loop2(&block)<br/> while true<br/> block.call<br/> end<br/> p "not reached"<br/> end<br/><br/> def test_loop<br/> puts "loop"<br/> i = 0 <br/> res = loop do <br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break "out", i if i > 8<br/> end <br/> p res<br/> puts "--"<br/> end<br/><br/> def test_loop2<br/> puts "loop2"<br/> i = 0 <br/> res = loop2 do <br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break "out", i if i > 8<br/> end <br/> p res<br/> puts "--"<br/> end<br/><br/> def test_while_loop<br/> puts "while-loop"<br/> i = 0 <br/> while true<br/> i += 1<br/> next if i % 2 == 1 <br/> p i<br/> break if i > 8<br/> end<br/> puts "----"<br/> while i > 0<br/> p i<br/> i -= 1<br/> end<br/> puts "--"<br/> end<br/><br/> def return_in_block(&block)<br/> p "return_in_block before"<br/> block.call<br/> p "return_in_block after"<br/> end<br/><br/> def test_return_in_block<br/> p "before"<br/> return_in_block { return 4 }<br/> p "after (NOT)"<br/> end<br/><br/> def test_proc<br/> p "test_proc"<br/> a = proc { return 0 }<br/> p a.call<br/> a = Proc.new { break 3 }<br/> p a.call<br/> end<br/><br/> def test<br/> test_three_times_yield<br/> test_three_times_block<br/> test_three_times_indirect<br/> test_three_times_yield2<br/> test_loop<br/> test_loop2<br/> test_while_loop<br/><br/> begin<br/> test_proc<br/> rescue LocalJumpError => e<br/> p e<br/> end<br/><br/> p test_return_in_block()<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_insertion_sort.rb<br/>#<br/><br/>module T_TestInsertionSort<br/>class TestInsertionSort<br/> def sort ary<br/> puts "Before insertion sort:"<br/> p ary<br/><br/> for i in 1..(ary.length-1) do<br/> n = i<br/> while n >= 1 && ary[n] < ary[n - 1] do<br/> if ary[n] < ary[n - 1]<br/> tmp = ary[n]<br/> ary[n] = ary[n - 1]<br/> ary[n - 1] = tmp<br/> end<br/> n -= 1<br/> end<br/> end<br/><br/> puts "After insertion sort:"<br/> p ary<br/> end<br/><br/> def self.main<br/> new.sort [3, 6, 2, 5, 3, 7, 1, 8]<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_lebewesen.rb<br/>#<br/><br/>module T_TestLebewesen<br/>class TestLebewesen<br/> def self.main<br/> leni = Katze.new("AA-BB", "Leni")<br/> flocki = Katze.new("AC-DC", "Flocki") <br/> bello = Hund.new("AA-ZZ")<br/> leni.miau<br/> bello.wau<br/> bello.jage(leni)<br/> end<br/>end<br/><br/>class Lebewesen<br/> def initialize(dns)<br/> @dns = dns<br/> end<br/>end<br/><br/>class Katze < Lebewesen<br/> attr_reader :name<br/><br/> def initialize(dns, name)<br/> super(dns)<br/> @name = name<br/> end<br/><br/> def miau<br/> puts "miau, ich bin " + @name<br/> end<br/>end<br/><br/>class Hund < Lebewesen<br/> def wau<br/> puts "wau wau"<br/> end<br/><br/> def jage(katze)<br/> puts "ich jage " + katze.name<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_expr.rb<br/>#<br/><br/>module T_TestExpr<br/>class TestExpr<br/> def test<br/> i = if true then 1 else 2 end<br/> p i<br/> i = true or return<br/> p i<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_simple_output.rb<br/>#<br/><br/>module T_TestSimpleOutput<br/>class TestSimpleOutput <br/> def self.main()<br/> puts "Hello World from RubyJS"<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_if.rb<br/>#<br/><br/>module T_TestIf<br/>class TestIf<br/> def test<br/> puts "OK" if true<br/> puts "NOT OK" if false<br/> puts "OK" unless false<br/> puts "NOT OK" unless true<br/> puts "OK" if true and true and (true or false) and (!false)<br/><br/> puts "OK" if 5 < 6 and 6 < 7<br/><br/> # test the "||" operator<br/> p(false || "a") # => "a"<br/> p(nil || "a") # => "a"<br/> p(true || "a") # => true<br/> p("b" || "a") # => "b"<br/><br/> # test the "&&" operator<br/><br/> p(false && "a") # => false<br/> p(nil && "a") # => nil<br/> p(true && "a") # => "a"<br/> p("b" && "a") # => "a"<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_class.rb<br/>#<br/><br/>module T_TestClass<br/>module X<br/>end<br/><br/>class A<br/> include X<br/>end<br/><br/>class B < A<br/>end<br/><br/>class C < B<br/>end<br/><br/>class D<br/>end<br/><br/>class TestClass<br/> def self.main<br/> p A.new.instance_of?(A) # => true<br/> p A.new.instance_of?(B) # => false<br/> p B.new.instance_of?(A) # => false<br/> p A.new.instance_of?(X) # => false<br/> p B.new.instance_of?(X) # => false<br/><br/> p A.new.kind_of?(A) # => true<br/> p A.new.kind_of?(B) # => false<br/> p B.new.kind_of?(A) # => true<br/> p A.new.kind_of?(X) # => true<br/> p B.new.kind_of?(X) # => true<br/><br/> p C.new.kind_of?(X) # => true<br/> p C.new.kind_of?(A) # => true<br/> p C.new.kind_of?(B) # => true<br/> p C.new.kind_of?(C) # => true<br/> p C.new.kind_of?(D) # => false<br/> p C.new.kind_of?(Object) # => true<br/> p C.new.kind_of?(Kernel) # => true<br/> p C.new.kind_of?(Class) # => false<br/><br/> p ("hallo".class.name)<br/> p (nil.class.name)<br/> p (nil.instance_of?(NilClass))<br/> p ("hallo".instance_of?(String))<br/> p ("hallo".class)<br/> p A<br/> p B<br/> p C<br/> p D<br/> p X<br/><br/> p X.name<br/> p A.name<br/> p B.name<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_case.rb<br/>#<br/><br/>module T_TestCase<br/>class TestCase<br/> def test<br/> case 1+1<br/> when 1, 3<br/> puts "NOT OKAY"<br/> when 2<br/> puts "OKAY"<br/> else<br/> puts "NOT OKAY"<br/> end<br/><br/> p (Array === [])<br/> p (RuntimeError === RuntimeError.new)<br/><br/> case 1<br/> when Fixnum <br/> puts "OK"<br/> when 1<br/> puts "OK"<br/> end<br/><br/> case 4<br/> when 0..3<br/> puts "NOT OKAY"<br/> when 1...4<br/> puts "NOT OKAY"<br/> when 2..4<br/> puts "OKAY"<br/> end<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_splat.rb<br/>#<br/><br/>module T_TestSplat<br/>class TestSplat<br/> def m(*args)<br/> p args<br/> end<br/><br/> def self.main<br/> obj = new()<br/><br/> obj.m<br/> obj.m(*[])<br/><br/> obj.m(1)<br/> obj.m(*[1])<br/> obj.m(1,*[])<br/><br/> obj.m(1,2)<br/> obj.m(*[1,2])<br/> obj.m(1,*[2])<br/> obj.m(1,*[1,2])<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_string.rb<br/>#<br/><br/>module T_TestString<br/>class TestString<br/> def test<br/> # inspect<br/> p "hello"<br/> p "hallo\b\t\n"<br/> p "hallo\\leute"<br/> p '"super"'<br/> <br/> # index<br/> p "hello".index('e')<br/> p "hello".index('lo')<br/> p "hello".index('a')<br/> p "hello hello".index('ll')<br/> p "hello hello".index('ll', 3)<br/><br/> # []<br/> p "hallo"[0,1]<br/> p "hallo"[0,2]<br/> p "hallo"[0,5]<br/><br/> p ("10".rjust(10, "0"))<br/> p ("10".rjust(1, "blah"))<br/> p ("x".rjust(4, "()"))<br/><br/> p ("10".ljust(10, "0"))<br/> p ("10".ljust(1, "blah"))<br/> p ("x".ljust(4, "()"))<br/><br/><br/> # string interpolation<br/> p "abc #{ 1 + 2 } def"<br/> @a = "hallo".inspect<br/> @b = 4.5<br/> p "#{@a},#{@b}"<br/><br/> # gsub<br/> s = "hallo".gsub("l", "r")<br/> p s<br/> s = "hallo".gsub(/ll/, "rr")<br/> p s<br/> s = "hallo".gsub(/l/) { "r" }<br/> p s<br/> s = "hallo".gsub(/ll/) { "blah blah" }<br/> p s<br/> "hallllllo".gsub(/(l)l/) {|i| p i }<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_inspect.rb<br/>#<br/><br/>module T_TestInspect<br/>class TestInspect<br/> def test<br/> o = [{"Hello"=>'Rubyconf'}]<br/> puts o.inspect<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_regexp.rb<br/>#<br/><br/>module T_TestRegexp<br/>class TestRegexp<br/> def test<br/> p "okay" if "hallo" =~ /ll/<br/> pos = "hallo" =~ /ll/<br/> p pos<br/><br/> "hallo" =~ /(ll)/<br/> p $1<br/> p $2<br/> p $3<br/><br/> "hallo" =~ /a(ll)(o)/<br/> p $1<br/> p $2<br/> p $3<br/> p $4<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_args.rb<br/>#<br/><br/>module T_TestArgs<br/>class TestArgs<br/> def m(a, b=1, c="hallo", *args) <br/> p a<br/> p b<br/> p c<br/> p args<br/> end<br/><br/> def self.main<br/> obj = new()<br/><br/> obj.m(0)<br/> puts "--"<br/> obj.m(1,2)<br/> puts "--"<br/> obj.m(1,2,9)<br/> puts "--"<br/> obj.m(1,2,9,5)<br/> puts "--"<br/> obj.m(1,2,9,5,6)<br/> puts "--"<br/> obj.m(1,2,9,5,6,7,8,9,10,11,12)<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_array.rb<br/>#<br/><br/>module T_TestArray<br/>class TestArray<br/> if $RUBYJS<br/> def array<br/> [1, 2, `null`, [`null`, `null`, 4]]<br/> end<br/> else<br/> def array<br/> [1, 2, nil, [nil, nil, 4]]<br/> end<br/> end<br/><br/> def test<br/> # delete<br/> a = [ "a", "b", "b", "b", "c" ]<br/> p a.delete("b") #=> "b"<br/> p a #=> ["a", "c"]<br/> p a.delete("z") #=> nil<br/><br/> puts "test native JS array mapping"<br/> p array()<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_eql.rb<br/>#<br/><br/>module T_TestEql<br/>class TestEql<br/> def self.main<br/> p "a".eql?("a") # => true<br/> p "a".eql?(1) # => false<br/> p "1".eql?(1) # => false<br/> p [1,2].eql?([1,2]) # => true<br/> p 1.eql?("1") # => false<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_send.rb<br/>#<br/><br/>module T_TestSend<br/>class A<br/> def a_method(a,b)<br/> p a, b<br/> end<br/>end<br/><br/>class B < A<br/> def a_method(b, a)<br/> p "in B"<br/> super<br/> end<br/><br/> def c_method(b)<br/> end<br/>end<br/><br/>class C<br/> def method_missing(id, *args, &block)<br/> p "mm: #{id}, #{args}"<br/> end<br/>end<br/><br/>class TestSend<br/> def self.main<br/> puts "send"<br/> p A.new.send("a_method", 1, 2)<br/> p B.new.send("a_method", 1, 2)<br/><br/> puts "respond_to?"<br/> p A.new.respond_to?(:a_method)<br/> p A.new.respond_to?(:to_s)<br/> p A.new.respond_to?(:inspect)<br/> p A.new.respond_to?(:b_method)<br/> p A.new.respond_to?(:c_method)<br/><br/> puts "method_missing"<br/> p C.new.respond_to?(:blah_blah)<br/> C.new.blah_blah(1,2,3)<br/><br/> begin<br/> A.new.blah_blah<br/> puts "FAILURE?"<br/> rescue NoMethodError<br/> puts "catched!!!"<br/> end<br/><br/> begin<br/> A.not_a_method<br/> rescue NoMethodError<br/> p "goood"<br/> end<br/><br/> puts "class Method"<br/> m = "hallo".method(:to_s)<br/> p m<br/> p m.call<br/><br/> a = [1,2,3]<br/> m = a.method(:+)<br/> p m<br/> p m.call([2,3])<br/> p m<br/> p a<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_range.rb<br/>#<br/><br/>module T_TestRange<br/>class TestRange<br/> def test<br/> a = Range.new(0,2)<br/> p a.first<br/> p a.last<br/> p a<br/><br/> i = 1<br/> p ((i..i+5).to_s)<br/> p ((i...i+i).to_s)<br/><br/> p ((0..2).to_s)<br/> p ((0...2).to_s)<br/><br/> (0..4).each do |i| p i end<br/> (0...4).each do |i| p i end<br/> (-1..-4).each do |i| p i end<br/><br/> p ((0..4).include?(4))<br/> p ((0..4).include?(5))<br/> p ((0...4).include?(5))<br/> p ((0...4).include?(4))<br/> p ((0...4).include?(3))<br/> p ((0...4).include?(0))<br/> p ((0...4).include?(-1))<br/><br/> p ((-1..-5).to_a)<br/> p ((-5..-1).to_a)<br/><br/> r = Range.new(0, 4)<br/> p r.first<br/> p r.begin<br/> p r.last<br/> p r.end<br/> p r.exclude_end?<br/><br/> r = 1...5<br/> p r.first<br/> p r.begin<br/> p r.last<br/> p r.end<br/> p r.exclude_end?<br/><br/> p (false == false)<br/> p (false == true)<br/> p (true == false)<br/> p (true == true)<br/><br/> p ((0..2) == (0..2))<br/> p ((0..2) == Range.new(0,2))<br/> p ((0..2) == (0...2))<br/><br/> j = 55<br/> p j<br/> for i in 1..100<br/> j = i<br/> end<br/> p j<br/><br/> j = 54<br/> p j<br/> for j in 1..100<br/> end<br/> p j<br/> end<br/><br/> def self.main<br/> new.test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_massign.rb<br/>#<br/><br/>module T_TestMassign<br/>class TestMassign<br/> def self.main<br/> a, b = 1, 2<br/> p a<br/> p b<br/> puts "--"<br/><br/> a, b = 1, 2, 3<br/> p a<br/> p b<br/> puts "--"<br/><br/> c = 5<br/> a, b, c = 1, 2 <br/> p a<br/> p b<br/> p c<br/> puts "--"<br/><br/> @a, b, @c = 1, 2, 3<br/> p @a<br/> p b<br/> p @c<br/> puts "--"<br/><br/> puts "swap"<br/> # swap<br/> a, b = 1, 2<br/> p a<br/> p b<br/> a, b = b, a<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat1"<br/> a, b, c, *d = 1, 2 <br/> p a<br/> p b<br/> p c<br/> p d<br/> puts "--"<br/><br/> puts "splat2"<br/> a, *b = 1, 2<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat3"<br/> a, *b = 1, 2, 3, 4, 5<br/> p a<br/> p b<br/> puts "--"<br/><br/> puts "splat with globals"<br/> p $a<br/> p $b<br/> $a, $b = 1, 2 <br/> p $a<br/> p $b<br/> puts "--"<br/> <br/> #TODO: a, b = 1 (to_ary)<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_hot_ruby.rb<br/>#<br/><br/>module T_TestHotRuby<br/>#<br/># Examples taken from: http://hotruby.accelart.jp/<br/>#<br/>class TestHotRuby<br/> def sort ary<br/> puts "Before insertion sort:"<br/> p ary<br/><br/> for i in 1..(ary.length-1) do<br/> n = i<br/> while n >= 1 && ary[n] < ary[n - 1] do<br/> if ary[n] < ary[n - 1]<br/> tmp = ary[n]<br/> ary[n] = ary[n - 1]<br/> ary[n - 1] = tmp<br/> end<br/> n -= 1<br/> end<br/> end<br/><br/> puts "After insertion sort:"<br/> p ary<br/> end<br/><br/> def addPrint a, b, c<br/> puts a + b + c<br/> end<br/><br/> def self.main<br/> t = new()<br/><br/> puts "InsertionSort"<br/> t.sort [3, 6, 2, 5, 3, 7, 1, 8]<br/><br/> puts "Array args"<br/> ary = [' World ', '!']<br/> t.addPrint 'Hello', *ary<br/><br/> puts "Block"<br/> Foo.new.main<br/><br/> puts "Class"<br/> puts Pi::PI<br/> # different precision on Ruby vs. Javascript<br/> puts Pi.new.calc.to_s[0,13] <br/><br/><br/> puts "Const"<br/> # FIXME<br/>=begin<br/> Bar_::Baz_.new.run <br/> Bar2.new.run<br/> Object::Bar2.new.run<br/> Bar3.new.run<br/>=end<br/> end<br/>end<br/><br/>#<br/># Block<br/>#<br/>class Hoge<br/> def add_msg &block<br/> block.call "is" # s/yield/call/<br/> end<br/>end<br/> <br/>class Foo<br/> NAME = ' - William Shakespeare'<br/> def main<br/> pre = "Action"<br/> @space = " "<br/> Hoge.new.add_msg do |msg|<br/> fuga = "eloquence"<br/> puts pre + @space + msg + @space + fuga + NAME<br/> end<br/> end<br/>end<br/><br/>#<br/># Class<br/>#<br/>class Pi<br/> def initialize<br/> @a = 355.0<br/> end<br/> <br/> def calc<br/> b = 113.0<br/> return @a / b<br/> end<br/> <br/> PI = 'PI is about'<br/>end<br/> <br/>#<br/># Const<br/># <br/>class Foo_<br/> CONST = 'Foo'<br/>end<br/><br/>class Bar_<br/> CONST = 'Bar'<br/><br/> class Baz_ < Foo_<br/> def run<br/> puts CONST # => "Bar" Outer class const<br/> # In this case, you have to specify if you want to see parent class const.<br/> puts Foo_::CONST # => "Foo"<br/> end<br/> end<br/>end<br/> <br/>class Foo2<br/> CONST = 'Foo'<br/>end<br/> <br/>CONST = 'Object'<br/> <br/>class Bar2 < Foo2<br/> def run<br/> puts CONST # => "Foo"<br/> end<br/>end<br/><br/># If you specify "Object", then const in Object is searched before.<br/>class Object<br/> class Bar2 < Foo2<br/> def run<br/> puts CONST # => "Object"<br/> end<br/> end<br/>end<br/> <br/>class Foo3<br/> CONST = 'Foo'<br/>end<br/>class Bar3 < Foo3<br/> def run<br/> puts CONST # => "Foo"<br/> #CONST = 'Bar' # Define Bar's const "CONST"<br/> puts CONST # => "Bar" (Foo::CONST is hidden)<br/> puts Foo3::CONST # => "Foo" (You can see by "::")<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_new.rb<br/>#<br/><br/>module T_TestNew<br/>class TestNew<br/> def initialize<br/> end<br/><br/> def test<br/> puts "test"<br/> end<br/><br/> def self.main()<br/> new().test<br/> end<br/>end<br/>end<br/><br/><br/>#<br/># file: test/test_exception.rb<br/>#<br/><br/>module T_TestException<br/>class TestException<br/> def self.main<br/><br/> p "before block"<br/> begin<br/> p "in block"<br/> end<br/> p "after block"<br/><br/> ###<br/> begin<br/> p "block"<br/> rescue<br/> p "rescue"<br/> rescue Exception => a<br/> p "another rescue"<br/> p a<br/> else<br/> p "else"<br/> end<br/><br/> p RuntimeError.new("test")<br/><br/> puts "before begin"<br/> begin<br/> puts "before raise"<br/> raise Exception, "blah" <br/> puts "after raise"<br/> rescue<br/> puts "noooo"<br/> rescue Exception => a<br/> p a<br/> puts "yes"<br/> ensure<br/> puts "ensure"<br/> end<br/> puts "after begin"<br/><br/> puts "--"<br/><br/> begin<br/> puts "abc"<br/> raise "r"<br/> rescue<br/> p $!<br/> puts "b"<br/> ensure<br/> puts "e"<br/> end<br/><br/> #<br/> # Test arity checks<br/> #<br/><br/> begin<br/> p("hallo".to_s(2))<br/> rescue ArgumentError => a<br/> p a<br/> end<br/> end<br/>end<br/>end<br/><br/><br/><br/> class TestSuite<br/> def self.main<br/> begin<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test hash'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestHash::TestHash.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test yield'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestYield::TestYield.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test insertion sort'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestInsertionSort::TestInsertionSort.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test lebewesen'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestLebewesen::TestLebewesen.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test expr'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestExpr::TestExpr.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test simple output'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSimpleOutput::TestSimpleOutput.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test if'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestIf::TestIf.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test class'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestClass::TestClass.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test case'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestCase::TestCase.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test splat'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSplat::TestSplat.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test string'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestString::TestString.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test inspect'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestInspect::TestInspect.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test regexp'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestRegexp::TestRegexp.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test args'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestArgs::TestArgs.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test array'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestArray::TestArray.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test eql'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestEql::TestEql.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test send'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestSend::TestSend.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test range'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestRange::TestRange.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test massign'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestMassign::TestMassign.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test hot ruby'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestHotRuby::TestHotRuby.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test new'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestNew::TestNew.main<br/> <br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> puts 'Test exception'<br/> puts '~~~~~~~~~~~~~~~~~~~~'<br/> T_TestException::TestException.main<br/> <br/> rescue Exception => a<br/> p "unhandled exception"<br/> p a<br/> end<br/> end<br/> end<br/> TestSuite.main unless $RUBYJS<br/> </pre>
|
4059
4349
|
</body></html>
|