@locustjs/test 1.6.2 → 1.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -923,6 +923,8 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
923
923
  });
924
924
  }
925
925
  }
926
+ } else {
927
+ ok = false;
926
928
  }
927
929
  }
928
930
  if (ok) {
@@ -998,6 +1000,8 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
998
1000
  });
999
1001
  }
1000
1002
  }
1003
+ } else {
1004
+ ok = true;
1001
1005
  }
1002
1006
  }
1003
1007
  if (ok) {
@@ -1040,13 +1044,13 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1040
1044
  return this.value();
1041
1045
  case 9:
1042
1046
  ok = true;
1043
- _context.next = 37;
1047
+ _context.next = 40;
1044
1048
  break;
1045
1049
  case 12:
1046
1050
  _context.prev = 12;
1047
1051
  _context.t0 = _context["catch"](6);
1048
1052
  if (!(ex !== undefined)) {
1049
- _context.next = 37;
1053
+ _context.next = 39;
1050
1054
  break;
1051
1055
  }
1052
1056
  if (!(0, _base.isPrimitive)(ex)) {
@@ -1127,8 +1131,13 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1127
1131
  status: "incorrect-throw-value"
1128
1132
  });
1129
1133
  case 37:
1134
+ _context.next = 40;
1135
+ break;
1136
+ case 39:
1137
+ ok = false;
1138
+ case 40:
1130
1139
  if (!ok) {
1131
- _context.next = 39;
1140
+ _context.next = 42;
1132
1141
  break;
1133
1142
  }
1134
1143
  throw new TestException({
@@ -1136,9 +1145,9 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1136
1145
  code: 1013,
1137
1146
  status: "ran-to-completion"
1138
1147
  });
1139
- case 39:
1148
+ case 42:
1140
1149
  return _context.abrupt("return", this);
1141
- case 40:
1150
+ case 43:
1142
1151
  case "end":
1143
1152
  return _context.stop();
1144
1153
  }
@@ -1180,14 +1189,14 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1180
1189
  return this.value();
1181
1190
  case 9:
1182
1191
  ok = false;
1183
- _context2.next = 38;
1192
+ _context2.next = 41;
1184
1193
  break;
1185
1194
  case 12:
1186
1195
  _context2.prev = 12;
1187
1196
  _context2.t0 = _context2["catch"](6);
1188
1197
  error = _context2.t0;
1189
1198
  if (!(ex !== undefined)) {
1190
- _context2.next = 38;
1199
+ _context2.next = 40;
1191
1200
  break;
1192
1201
  }
1193
1202
  if (!(0, _base.isPrimitive)(ex)) {
@@ -1268,8 +1277,13 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1268
1277
  status: "incorrect-throw-value"
1269
1278
  });
1270
1279
  case 38:
1280
+ _context2.next = 41;
1281
+ break;
1282
+ case 40:
1283
+ ok = true;
1284
+ case 41:
1271
1285
  if (!ok) {
1272
- _context2.next = 40;
1286
+ _context2.next = 43;
1273
1287
  break;
1274
1288
  }
1275
1289
  throw new TestException({
@@ -1278,9 +1292,9 @@ var Expect = exports.Expect = /*#__PURE__*/function () {
1278
1292
  status: "ran-to-error",
1279
1293
  innerException: error
1280
1294
  });
1281
- case 40:
1295
+ case 43:
1282
1296
  return _context2.abrupt("return", this);
1283
- case 41:
1297
+ case 44:
1284
1298
  case "end":
1285
1299
  return _context2.stop();
1286
1300
  }
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@locustjs/test",
3
- "version": "1.6.2",
3
+ "version": "1.6.3",
4
4
  "description": "This library provides a simple test runner.",
5
- "main": "index.cjs.js",
6
- "module": "index.esm.js",
5
+ "main": "dist/index.js",
6
+ "module": "src/index.js",
7
7
  "scripts": {
8
- "build": "babel index.esm.js -o index.cjs.js",
8
+ "build": "babel ./src/index.js -o ./dist/index.js",
9
9
  "test": "node -r esm ./tests/index.js"
10
10
  },
11
11
  "repository": {
@@ -886,6 +886,8 @@ class Expect {
886
886
  });
887
887
  }
888
888
  }
889
+ } else {
890
+ ok = false;
889
891
  }
890
892
  }
891
893
 
@@ -964,6 +966,8 @@ class Expect {
964
966
  });
965
967
  }
966
968
  }
969
+ } else {
970
+ ok = true;
967
971
  }
968
972
  }
969
973
 
@@ -1040,6 +1044,8 @@ class Expect {
1040
1044
  });
1041
1045
  }
1042
1046
  }
1047
+ } else {
1048
+ ok = false;
1043
1049
  }
1044
1050
  }
1045
1051
 
@@ -1118,6 +1124,8 @@ class Expect {
1118
1124
  });
1119
1125
  }
1120
1126
  }
1127
+ } else {
1128
+ ok = true;
1121
1129
  }
1122
1130
  }
1123
1131
 
package/tests/index.js CHANGED
@@ -90,7 +90,7 @@ const tests = [
90
90
  [
91
91
  "Test 7: error",
92
92
  function (expect) {
93
- const x = 10;
93
+ const x = 30;
94
94
 
95
95
  expect(x).toBeGreaterThan(20);
96
96
  },