"use strict";
/* Socket Lib - Built with esbuild */
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var test_exports = {};
__export(test_exports, {
  getJestWorkerId: () => getJestWorkerId,
  getVitest: () => getVitest,
  isTest: () => isTest
});
module.exports = __toCommonJS(test_exports);
var import_boolean = require("./boolean");
var import_string = require("./string");
var import_node_env = require("./node-env");
var import_rewire = require("./rewire");
// @__NO_SIDE_EFFECTS__
function getJestWorkerId() {
  return (0, import_string.envAsString)((0, import_rewire.getEnvValue)("JEST_WORKER_ID"));
}
// @__NO_SIDE_EFFECTS__
function getVitest() {
  return (0, import_boolean.envAsBoolean)((0, import_rewire.getEnvValue)("VITEST"));
}
// @__NO_SIDE_EFFECTS__
function isTest() {
  const nodeEnv = (0, import_string.envAsString)((0, import_node_env.getNodeEnv)());
  return nodeEnv === "test" || /* @__PURE__ */ getVitest() || !!/* @__PURE__ */ getJestWorkerId();
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
  getJestWorkerId,
  getVitest,
  isTest
});
