项目原始demo,不改动
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
Tento repozitář je archivovaný. Můžete prohlížet soubory, klonovat, ale nemůžete nahrávat a vytvářet nové úkoly a požadavky na natažení.
 
 
 
 

31 řádky
579 B

  1. "use strict";
  2. module.exports = function (t, a) {
  3. var x;
  4. a.throws(function () {
  5. t();
  6. }, TypeError, "Undefined");
  7. a.throws(function () {
  8. t(null);
  9. }, TypeError, "Null");
  10. a.throws(function () {
  11. t(0);
  12. }, TypeError, "Number");
  13. a.throws(function () {
  14. t(true);
  15. }, TypeError, "Boolean");
  16. a.throws(function () {
  17. t("raz");
  18. }, TypeError, "String");
  19. a.throws(function () {
  20. t(function () {});
  21. }, TypeError, "Function");
  22. a.throws(function () {
  23. t({});
  24. }, TypeError, "Object");
  25. a.throws(function () {
  26. t({ length: 0 });
  27. }, TypeError, "Array-like");
  28. a(t(x = []), x, "Array");
  29. };