Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions LARAI/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,9 @@ dependencies {

// Testing dependencies
testImplementation 'org.junit.jupiter:junit-jupiter:5.10.0'
testImplementation 'org.mockito:mockito-core:5.5.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.5.0'
testImplementation 'org.mockito:mockito-core:5.23.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.23.0'
testImplementation 'org.assertj:assertj-core:3.24.2'
testImplementation 'org.mockito:mockito-inline:5.2.0' // For static mocking
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.10.0'
}

Expand Down
31 changes: 31 additions & 0 deletions Lara-JS/code/generate-ts-joinpoints.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import fs from "fs";
import os from "os";
import path from "path";
import { generateEnums } from "../scripts/generate-ts-joinpoints.ts";

describe("generateEnums", () => {
it("preserves the enum values from the language specification", () => {
const outputDirectory = fs.mkdtempSync(
path.join(os.tmpdir(), "lara-build-interfaces-"),
);
const outputPath = path.join(outputDirectory, "Joinpoints.ts");

try {
const outputFile = fs.openSync(outputPath, "w");
try {
generateEnums(
[{ name: "StorageClass", entries: ["NONE", "PRIVATE_EXTERN", "STATIC"] }],
outputFile,
);
} finally {
fs.closeSync(outputFile);
}

const output = fs.readFileSync(outputPath, "utf8");
expect(output).toContain(' STATIC: "STATIC",');
expect(output).toContain(' PRIVATE_EXTERN: "PRIVATE_EXTERN",');
} finally {
fs.rmSync(outputDirectory, { recursive: true, force: true });
}
});
});
2 changes: 1 addition & 1 deletion Lara-JS/scripts/generate-ts-joinpoints.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ function generateEnum(e: ConvertedEnum, outputFile: number) {
*/\n`);
fs.writeSync(outputFile, `export const ${e.name} = {\n`);
e.entries.forEach((entry) => {
fs.writeSync(outputFile, ` ${entry}: "${entry.toLowerCase()}",\n`);
fs.writeSync(outputFile, ` ${entry}: "${entry}",\n`);
});
fs.writeSync(outputFile, `} as const;\n`);
fs.writeSync(
Expand Down
5 changes: 2 additions & 3 deletions LaraUtils/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ dependencies {

// Testing dependencies
testImplementation 'org.junit.jupiter:junit-jupiter:5.10.0'
testImplementation 'org.mockito:mockito-core:5.5.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.5.0'
testImplementation 'org.mockito:mockito-core:5.23.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.23.0'
testImplementation 'org.assertj:assertj-core:3.24.2'
testImplementation 'org.mockito:mockito-inline:5.2.0' // For static mocking
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.10.0'
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ void testRunCommand_withNullTimeout_handlesGracefully() {
// Given
String command = "echo hello";
boolean printToConsole = false;
long timeoutNanos = 2000000000; // 2 seconds
Long timeoutNanos = null;

// When
ProcessOutputAsString result = LaraSystemTools.runCommand(command, workingDirectory, printToConsole, timeoutNanos);
Expand Down
5 changes: 2 additions & 3 deletions WeaverGen2/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,9 @@ dependencies {

// Testing dependencies
testImplementation 'org.junit.jupiter:junit-jupiter:5.10.0'
testImplementation 'org.mockito:mockito-core:5.5.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.5.0'
testImplementation 'org.mockito:mockito-core:5.23.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.23.0'
testImplementation 'org.assertj:assertj-core:3.24.2'
testImplementation 'org.mockito:mockito-inline:5.2.0' // For static mocking
testImplementation 'org.junit-pioneer:junit-pioneer:2.3.0' // For test retries
testImplementation 'com.github.stefanbirkner:system-lambda:1.2.1'
testImplementation 'com.google.guava:guava:33.4.0-jre'
Expand Down
5 changes: 2 additions & 3 deletions WeaverInterface/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,9 @@ dependencies {

// Testing dependencies
testImplementation 'org.junit.jupiter:junit-jupiter:5.10.0'
testImplementation 'org.mockito:mockito-core:5.5.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.5.0'
testImplementation 'org.mockito:mockito-core:5.23.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.23.0'
testImplementation 'org.assertj:assertj-core:3.24.2'
testImplementation 'org.mockito:mockito-inline:5.2.0' // For static mocking
testImplementation 'org.junit-pioneer:junit-pioneer:2.3.0' // For test retries
testImplementation 'com.github.stefanbirkner:system-lambda:1.2.1'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.10.0'
Expand Down
Loading