All files / output zcl_abapgit_frontend_services.clas.testclasses.mjs

100% Statements 46/46
90% Branches 9/10
88.88% Functions 8/9
100% Lines 46/46

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 461x 1x 1x 1x 3x 3x 3x 3x 3x 3x 1x 1x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 3x 1x 1x 3x 1x 1x 3x 1x 1x 3x 1x 1x
const {zcl_abapgit_frontend_services} = await import("./zcl_abapgit_frontend_services.clas.mjs");
const {cx_root} = await import("./cx_root.clas.mjs");
// zcl_abapgit_frontend_services.clas.testclasses.abap
 
class ltcl_frontend_services {
  static INTERNAL_TYPE = 'CLAS';
  static INTERNAL_NAME = 'CLAS-ZCL_ABAPGIT_FRONTEND_SERVICES-LTCL_FRONTEND_SERVICES';
  static IMPLEMENTED_INTERFACES = [];
  static ATTRIBUTES = {"MO_CUT": {"type": () => {return new abap.types.ABAPObject({qualifiedName: "ZCL_ABAPGIT_FRONTEND_SERVICES", RTTIName: "\\CLASS=ZCL_ABAPGIT_FRONTEND_SERVICES"});}, "visibility": "I", "is_constant": " ", "is_class": " "}};
  static METHODS = {"SETUP": {"visibility": "I", "parameters": {}},
  "PATH_WINDOWS": {"visibility": "I", "parameters": {}},
  "PATH_UNIX": {"visibility": "I", "parameters": {}},
  "NO_PATH": {"visibility": "I", "parameters": {}}};
  #mo_cut;
  constructor() {
    this.me = new abap.types.ABAPObject();
    this.me.set(this);
    this.INTERNAL_ID = abap.internalIdCounter++;
    this.FRIENDS_ACCESS_INSTANCE = {
      "setup": this.#setup.bind(this),
      "path_windows": this.#path_windows.bind(this),
      "path_unix": this.#path_unix.bind(this),
      "no_path": this.#no_path.bind(this),
    };
    this.#mo_cut = new abap.types.ABAPObject({qualifiedName: "ZCL_ABAPGIT_FRONTEND_SERVICES", RTTIName: "\\CLASS=ZCL_ABAPGIT_FRONTEND_SERVICES"});
    this.FRIENDS_ACCESS_INSTANCE["mo_cut"] = this.#mo_cut;
  }
  async constructor_(INPUT) {
    if (super.constructor_) { await super.constructor_(INPUT); }
    return this;
  }
  async #setup() {
    this.#mo_cut.set(await (new abap.Classes['ZCL_ABAPGIT_FRONTEND_SERVICES']()).constructor_());
  }
  async #path_windows() {
    await abap.Classes['CL_ABAP_UNIT_ASSERT'].assert_equals({act: (await this.#mo_cut.get().FRIENDS_ACCESS_INSTANCE["get_path_from_fullname"]({iv_fullname: abap.CharacterFactory.get(30, 'C:\\SAPworkdir\\hello\\world.abap')})), exp: abap.CharacterFactory.get(20, 'C:\\SAPworkdir\\hello\\')});
  }
  async #path_unix() {
    await abap.Classes['CL_ABAP_UNIT_ASSERT'].assert_equals({act: (await this.#mo_cut.get().FRIENDS_ACCESS_INSTANCE["get_path_from_fullname"]({iv_fullname: abap.CharacterFactory.get(19, '/var/tmp/world.abap')})), exp: abap.CharacterFactory.get(9, '/var/tmp/')});
  }
  async #no_path() {
    await abap.Classes['CL_ABAP_UNIT_ASSERT'].assert_equals({act: (await this.#mo_cut.get().FRIENDS_ACCESS_INSTANCE["get_path_from_fullname"]({iv_fullname: abap.CharacterFactory.get(12, 'toronto.abap')})), exp: abap.CharacterFactory.get(1, '')});
  }
}
abap.Classes['CLAS-ZCL_ABAPGIT_FRONTEND_SERVICES-LTCL_FRONTEND_SERVICES'] = ltcl_frontend_services;
export {ltcl_frontend_services};