Sha256: b9f904e0dc0ecbafc45fc1545327302d3690adabefd415ae75019a16d7e47ac0

Contents?: true

Size: 1 KB

Versions: 51

Compression:

Stored size: 1 KB

Contents

open Core
open Yojson.Basic
include Ocaml_special_cases 

type language_config = {
  template_file_name: string;
  default_base_folder: string;
  test_start_marker: string;
  test_end_marker: string;
  version_printer: string -> string;
  edit_expected: stringify: (json -> string) -> slug: string -> value: json -> string;
}

let default_language_config = function
| "ocaml" -> {
    template_file_name = "test.ml"; 
    default_base_folder = "../..";
    test_start_marker = "(* TEST"; 
    test_end_marker = "END TEST";
    version_printer = (fun v -> "(* Test/exercise version: \"" ^ v ^ "\" *)\n\n");
    edit_expected = ocaml_edit_expected;
    }
| "purescript" ->  {
    template_file_name = "Main.purs"; 
    default_base_folder = "../../../xpurescript";
    test_start_marker = "--TEST"; 
    test_end_marker = "--END TEST";
    version_printer = (fun v -> "-- Test/exercise version: \"" ^ v ^ "\"\n\n");
    edit_expected = Purescript_special_cases.edit_expected;
    }
| x -> failwith @@ "unknown language " ^ x

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
trackler-2.2.0.6 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.5 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.4 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.3 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.2 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.1 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.2.0.0 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.55 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.54 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.53 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.52 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.51 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.50 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.49 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.48 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.47 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.46 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.45 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.44 tracks/ocaml/tools/test-generator/src/languages.ml
trackler-2.1.0.43 tracks/ocaml/tools/test-generator/src/languages.ml