This repository was archived by the owner on Sep 3, 2024. It is now read-only.
File tree 12 files changed +23
-21
lines changed
12 files changed +23
-21
lines changed Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import path from "path" ;
4
- import { DiffMessage } from "../models/pub_messages" ;
5
- import { JSONParser } from "../parsers/parser_json" ;
4
+ import { DiffMessage } from "../models/pub_messages.js " ;
5
+ import { JSONParser } from "../parsers/parser_json.js " ;
6
6
7
7
export class DiffMessageBuilder {
8
8
/** Class to build diff message objects out of diff entries */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
- import { Dataclass } from "./data_class" ;
3
+ import { Dataclass } from "./data_class.js " ;
4
4
5
5
export class DiffMessage extends Dataclass {
6
6
/** Class for the data-diff message fields */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
- import { Dataclass } from "./data_class" ;
4
- import { MSG_SOURCE_VALUES } from "./pub_constants" ;
5
- import { MSG_TYPE_VALUES } from "./pub_constants" ;
3
+ import { Dataclass } from "./data_class.js " ;
4
+ import { MSG_SOURCE_VALUES } from "./pub_constants.js " ;
5
+ import { MSG_TYPE_VALUES } from "./pub_constants.js " ;
6
6
7
7
export class MessageMetadata extends Dataclass {
8
8
/** Class for the message metadata fields */
Original file line number Diff line number Diff line change 2
2
3
3
import fs from "fs" ;
4
4
import { EOL } from "os" ;
5
- import { DiffEntry } from "../models/diff_entries" ;
6
- import { JSONParser } from "./parser_json" ;
5
+ import { DiffEntry } from "../models/diff_entries.js " ;
6
+ import { JSONParser } from "./parser_json.js " ;
7
7
8
8
export class JDDiffParser {
9
9
/**
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import assert from "assert" ;
4
- import { DiffEntry , ARRAY_FIELD_NAME } from "../../src/models/diff_entries" ;
5
- import { DiffMessage } from "../../src/models/pub_messages" ;
6
- import { DiffMessageBuilder } from "../../src/builders/build_message" ;
4
+ import { DiffEntry , ARRAY_FIELD_NAME } from "../../src/models/diff_entries.js " ;
5
+ import { DiffMessage } from "../../src/models/pub_messages.js " ;
6
+ import { DiffMessageBuilder } from "../../src/builders/build_message.js " ;
7
7
8
8
describe ( "DiffMessageBuilder" , function ( ) {
9
9
/** Set of tests for the DiffMessageBuilder object */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import assert from "assert" ;
4
- import { Dataclass } from "../../src/models/data_class" ;
4
+ import { Dataclass } from "../../src/models/data_class.js " ;
5
5
6
6
describe ( "Dataclass" , function ( ) {
7
7
/** Set of tests for the Dataclass object */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import assert from "assert" ;
4
- import { DiffEntry , ARRAY_FIELD_NAME } from "../../src/models/diff_entries" ;
4
+ import { DiffEntry , ARRAY_FIELD_NAME } from "../../src/models/diff_entries.js " ;
5
5
6
6
describe ( "DiffEntry" , function ( ) {
7
7
/** Set of tests for the DiffEntry object */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import assert from "assert" ;
4
- import { DiffMessage } from "../../src/models/pub_messages" ;
4
+ import { DiffMessage } from "../../src/models/pub_messages.js " ;
5
5
6
6
describe ( "DiffMessage" , function ( ) {
7
7
/** Set of tests for the Diff message object */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import assert from "assert" ;
4
- import { MessageMetadata } from "../../src/models/pub_metadata" ;
5
- import { MSG_SOURCE_GHA , MSG_TYPE_DIFF } from "../../src/models/pub_constants" ;
4
+ import { MessageMetadata } from "../../src/models/pub_metadata.js " ;
5
+ import { MSG_SOURCE_GHA , MSG_TYPE_DIFF } from "../../src/models/pub_constants.js " ;
6
6
7
7
describe ( "MessageMetadata" , function ( ) {
8
8
/** Set of tests for the Message metadata object */
Original file line number Diff line number Diff line change 2
2
3
3
import assert from "assert" ;
4
4
import path from "path" ;
5
- import { DIFFS_FOLDER } from "../paths" ;
6
- import { JDDiffParser } from "../../src/parsers/parser_diff" ;
5
+ import { DIFFS_FOLDER } from "../paths.js " ;
6
+ import { JDDiffParser } from "../../src/parsers/parser_diff.js " ;
7
7
8
8
describe ( "JDDiffParser" , function ( ) {
9
9
/** Set of tests for the JD diff parser */
Original file line number Diff line number Diff line change 2
2
3
3
import assert from "assert" ;
4
4
import path from "path" ;
5
- import { JSONS_FOLDER } from "../paths" ;
6
- import { JSONParser } from "../../src/parsers/parser_json" ;
5
+ import { JSONS_FOLDER } from "../paths.js " ;
6
+ import { JSONParser } from "../../src/parsers/parser_json.js " ;
7
7
8
8
describe ( "JSONParser" , function ( ) {
9
9
/** Set of tests for the JSON data parser */
Original file line number Diff line number Diff line change 1
1
/* encoding: utf-8 */
2
2
3
3
import path from "path" ;
4
+ import { fileURLToPath } from "url" ;
4
5
5
- const PROJECT_PATH = path . dirname ( __filename ) ;
6
+ const FILE_PATH = fileURLToPath ( import . meta. url ) ;
7
+ const PROJECT_PATH = path . dirname ( FILE_PATH ) ;
6
8
7
9
export const DATA_FOLDER = path . join ( PROJECT_PATH , "_data" ) ;
8
10
export const DIFFS_FOLDER = path . join ( DATA_FOLDER , "diffs" ) ;
You can’t perform that action at this time.
0 commit comments