New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@syntest/search

Package Overview
Dependencies
Maintainers
4
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@syntest/search - npm Package Compare versions

Comparing version 0.5.0-beta.1 to 0.5.0-beta.2

4

dist/lib/ExecutionResult.d.ts

@@ -21,2 +21,6 @@ import { Trace } from "./Trace";

/**
* Return error identifier that occurred during the execution.
*/
getErrorIdentifier(): string;
/**
* Return all the traces produced by the execution.

@@ -23,0 +27,0 @@ */

2

dist/lib/objective/managers/ArchiveBasedObjectiveManager.d.ts

@@ -6,4 +6,2 @@ import { Encoding } from "../../Encoding";

* An abstract objective manager for algorithms based on an archive.
*
* @author Mitchell Olsthoorn
*/

@@ -10,0 +8,0 @@ export declare abstract class ArchiveBasedObjectiveManager<T extends Encoding> extends ObjectiveManager<T> {

@@ -21,8 +21,5 @@ "use strict";

exports.ArchiveBasedObjectiveManager = void 0;
const ExceptionObjectiveFunction_1 = require("../ExceptionObjectiveFunction");
const ObjectiveManager_1 = require("./ObjectiveManager");
/**
* An abstract objective manager for algorithms based on an archive.
*
* @author Mitchell Olsthoorn
*/

@@ -51,26 +48,3 @@ class ArchiveBasedObjectiveManager extends ObjectiveManager_1.ObjectiveManager {

finalize(_finalPopulation) {
const encodings = this._archive.getEncodings();
for (const encoding of encodings) {
const uses = this._archive.getUses(encoding);
for (const use of uses) {
if (use instanceof ExceptionObjectiveFunction_1.ExceptionObjectiveFunction) {
encoding.addMetaComment(`Selected for:`);
for (const line of use.error.stack.split("\n")) {
encoding.addMetaComment(`\t${line}`);
}
encoding.addMetaComment("");
}
else {
encoding.addMetaComment(`Selected for objective: ${use.getIdentifier()}`);
}
}
const executionResult = encoding.getExecutionResult();
if (executionResult) {
for (const objective of this._subject.getObjectives()) {
if (executionResult.coversId(objective.getIdentifier())) {
encoding.addMetaComment(`Covers objective: ${objective.getIdentifier()}`);
}
}
}
}
// pass
}

@@ -77,0 +51,0 @@ /**

@@ -21,3 +21,2 @@ "use strict";

exports.ObjectiveManager = void 0;
const crypto = require("node:crypto");
const logging_1 = require("@syntest/logging");

@@ -86,13 +85,3 @@ const Archive_1 = require("../../Archive");

if (this._exceptionObjectivesEnabled && result.hasError()) {
let stack = result.getError().stack;
stack = stack
? stack
.split("\n")
// only use location lines
.filter((line) => line.startsWith(" at"))
// only use locations within the source code (i.e. not from the generated tests)
.filter((line) => line.includes("/instrumented/")) // stupid hack should be done better somehow, suffices for now
.join("\n")
: result.getError().message;
const hash = crypto.createHash("md5").update(stack).digest("hex");
const hash = result.getErrorIdentifier();
const numberOfExceptions = this._archive

@@ -99,0 +88,0 @@ .getObjectives()

@@ -6,4 +6,2 @@ import { Encoding } from "../../Encoding";

* An abstract objective manager for algorithms based on populations.
*
* @author Mitchell Olsthoorn
*/

@@ -10,0 +8,0 @@ export declare abstract class PopulationBasedObjectiveManager<T extends Encoding> extends ObjectiveManager<T> {

@@ -21,8 +21,5 @@ "use strict";

exports.PopulationBasedObjectiveManager = void 0;
const ExceptionObjectiveFunction_1 = require("../ExceptionObjectiveFunction");
const ObjectiveManager_1 = require("./ObjectiveManager");
/**
* An abstract objective manager for algorithms based on populations.
*
* @author Mitchell Olsthoorn
*/

@@ -57,27 +54,3 @@ class PopulationBasedObjectiveManager extends ObjectiveManager_1.ObjectiveManager {

}
const executionResult = encoding.getExecutionResult();
if (executionResult) {
for (const objective of this._subject.getObjectives()) {
if (executionResult.coversId(objective.getIdentifier())) {
encoding.addMetaComment(`Covers objective: ${objective.getIdentifier()}`);
}
}
}
}
const encodings = this._archive.getEncodings();
for (const encoding of encodings) {
const uses = this._archive.getUses(encoding);
for (const use of uses) {
if (use instanceof ExceptionObjectiveFunction_1.ExceptionObjectiveFunction) {
encoding.addMetaComment(`Selected for:`);
for (const line of use.error.stack.split("\n")) {
encoding.addMetaComment(`\t${line}`);
}
encoding.addMetaComment("");
}
else {
encoding.addMetaComment(`Selected for objective: ${use.getIdentifier()}`);
}
}
}
}

@@ -84,0 +57,0 @@ }

{
"name": "@syntest/search",
"version": "0.5.0-beta.1",
"version": "0.5.0-beta.2",
"description": "The common core of the SynTest Framework",

@@ -64,3 +64,3 @@ "keywords": [

},
"gitHead": "05e3f65f4ead39eb943c25b246f7e21b3e29a21b"
"gitHead": "b3bc840eaaaf34a76776d6099e90c91e4875e61d"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc