Commit Graph

9 Commits

Author SHA1 Message Date
Don Cross
23ed1cda5a Kotlin: added more planet longitude tests.
Generate longitude output files that are tested by
the `generate` program.

Discovered that Windows `run.bat` was not correctly testing
the longitude output test files generated by the JavaScript
code. Fixed that.
2022-04-17 13:30:09 -04:00
Ebrahim Byagowi
7ad9487c3e kotlin: Upgrade Android example to use the new namings 2022-04-12 23:29:09 +04:30
Don Cross
79ff7b2805 Kotlin: Create fatJar during initial build.
Moved the step that creates the fatJar into
the main build process for Kotlin. This is
needed to run the Java demos, and it is good
to fail early if it cannot be built.
2022-04-12 10:37:02 -04:00
Don Cross
e46c0cf8c6 Kotlin: Compare test output to NOVAS C 3.1.
Instead of relying only on diffcalc to catch calculation
errors, call `generate check` before proceeding with other
unit tests. This way, breakage can be more quickly isolated
to the Kotlin code, if it is the culprit.
2022-04-03 10:43:20 -04:00
Don Cross
9ae0ba1e01 Dump unit test failures to GitHub Actions log.
If the Kotlin unit tests fail on my home system,
I can easily read them. But if they fail on GitHub Actions,
I would have no idea what went wrong. So now I dump
the XML output of the unit tests if the gradlew command
fails for any reason. Then I can see the problem in
the GitHub Actions console log.
2022-03-26 02:24:46 -04:00
Don Cross
fa499d75cc Fixed broken unit tests due to stale Dokka output.
I didn't realize Dokka doesn't clean up its output directory
before writing documentation files. This caused stale documentation
to still exist from previous builds. The result was a failed
unit test because the generated documentation did not match
what was checked into git.

In general, I want to make sure that builds I run on my development
system exactly match what GitHub Actions does on its cloud platform.
So before running the `gradlew` build step, I delete the entire
directory source/kotlin/build. This directory is always absent
on GitHub Actions, which makes my local build better match the
remote build.
2022-03-24 09:47:22 -04:00
Don Cross
53c8d7145a Publish generated Kotlin documentation to GitHub.
Merge a custom Markdown prefix with documentation
generated by dokka from Kotlin source code into
the published GitHub page. See the new script:

    generate/kotlindoc/format_kotlin_doc.py

The result is not yet quite what I want, but it
is much better than nothing.

Things to improve:

The `object Astronomy` link should not be hidden
in the middle of the other types. It should be
expanded and promoted to the top level.
2022-03-23 20:36:00 -04:00
Don Cross
0f0fab513a Kotlin: implemented Body enum with code docs.
Implemented the Body enum, with documentation strings
in comments. Reworked the Gradle build to generate
GitHub Flavored Markdown (gfm) instead of html.
2022-03-18 20:10:51 -04:00
Don Cross
a0723c7406 Kotlin build/test integrated with 'run' scripts.
Instead of being executed directly by the GitHub Actions
yml file, the Kotlin build now has been integrated with
the build/test steps for the other 4 languages in the
bash script `generate/run` and the Windows batch file
`generate/run.bat`. This will be necessary to control the
order of execution, because the Kotlin source code will have
to be written by the code generator before it is built
and executed.

I also added hints for myself and other contributors about
how to set up Kotlin/JDK tools on a new developement machine.
These instructions are not needed by most users of Astronomy Engine,
just contributors.
2022-03-17 20:52:32 -04:00