Skip to content

Conversation

@Samy-33
Copy link
Contributor

@Samy-33 Samy-33 commented Dec 6, 2025

Bash tests

.jank based modules

  • Overrides all .cljc, .cpp based modules if the module name is the same

  • Source

    • loaded from filesystem: Tested through test/bash/module/cljc
    • loading from a jar: Tested through test/bash/module/jar directory

.cljc based modules

  • Loadable with correct reader conditional
  • Overriden by .jank based modules

.cpp based modules

  • correctly loads
  • Overriden by both .jank and .cljc based modules

compiled modules (.o)

  • Source
    • Should be loadable from filesystem
    • Not loadable from a jar
  • If source file doesn't exist, fail to load
  • If source is more recent than the compiled module, use the source

Module reloading

Dependency resolution

  • All permutations of these types of module should be loadable.
    • .jank -> .cljc -> .cpp -> .o
    • .jank -> .cljc -> .o -> .cpp
    • And so on..

fixes #363

@Samy-33 Samy-33 changed the title test(module-loader): bash test for cpp loading and preference checks test(module-loader): bash tests Dec 6, 2025
.jank overrides .cljc overrides .cpp based modules
@Samy-33 Samy-33 force-pushed the module-loader-tests branch from 446da40 to 9122308 Compare December 6, 2025 10:56
@Samy-33 Samy-33 marked this pull request as draft December 6, 2025 16:36
@Samy-33 Samy-33 force-pushed the module-loader-tests branch from b68df26 to e266633 Compare December 6, 2025 16:56
@Samy-33 Samy-33 force-pushed the module-loader-tests branch from 4ee162e to 59ea5d7 Compare December 6, 2025 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add bash tests for module loading

1 participant