
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
@expressen/tallahassee
Advanced tools
Test your client scripts in a headless browser.
Supports just about everything except querySelectorAll()
which we don´t want developers to use.
"use strict";
const app = require("../app/express-js-app");
const Browser = require("@expressen/tallahassee");
const {Compiler} = require("@expressen/tallahassee/lib/Compiler");
describe("Tallahassee", () => {
before(() => {
Compiler([/assets\/scripts/]);
});
describe("navigateTo()", () => {
it("navigates to url", async () => {
await Browser(app).navigateTo("/");
});
it("throws if not 200", async () => {
try {
await Browser(app).navigateTo("/../");
} catch (e) {
var err = e; // eslint-disable-line no-var
}
expect(err).to.be.ok;
});
});
describe("run script", () => {
it("transpiles and runs es6 script", async () => {
const browser = await Browser(app).navigateTo("/", {
Cookie: "_ga=1"
});
require("../app/assets/scripts/main");
expect(browser.document.cookie).to.equal("_ga=1;");
expect(browser.document.getElementsByClassName("set-by-js")).to.have.length(1);
});
it("again", async () => {
const browser = await Browser(app).navigateTo("/");
require("../app/assets/scripts/main");
expect(browser.document.cookie).to.equal("");
expect(browser.document.getElementsByClassName("set-by-js")).to.have.length(0);
});
});
});
"use strict";
const app = require("../app/express-js-app");
const Browser = require("@expressen/tallahassee");
const {Compiler, IntersectionObserver, ElementScroller} = require("@expressen/tallahassee/lib");
describe("IntersectionObserver", () => {
before(() => {
Compiler.Compiler([/assets\/scripts/]);
});
it("observes elements", async () => {
const browser = await Browser(app).navigateTo("/", {
Cookie: "_ga=1"
});
const intersectionObserver = browser.window.IntersectionObserver = IntersectionObserver(browser);
require("../app/assets/scripts/main");
expect(intersectionObserver._getObserved()).to.have.length(1);
});
it("listens to window scroll", async () => {
const browser = await Browser(app).navigateTo("/", {
Cookie: "_ga=1"
});
browser.window.IntersectionObserver = IntersectionObserver(browser);
require("../app/assets/scripts/main");
const scroller = ElementScroller(browser, () => {
return browser.document.getElementsByClassName("lazy-load");
});
scroller.scrollToTopOfElement(browser.document.getElementsByClassName("lazy-load")[0]);
expect(browser.document.getElementsByClassName("lazy-load").length).to.equal(0);
expect(browser.document.getElementsByTagName("img")[1].src).to.be.ok;
});
});
10.4.0
min-width
and max-width
in matchMedia
matchMedia
FAQs
Lightweight client testing framework
The npm package @expressen/tallahassee receives a total of 320 weekly downloads. As such, @expressen/tallahassee popularity was classified as not popular.
We found that @expressen/tallahassee demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.