Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cross-build for JS+Native #409

Merged
merged 7 commits into from
Jun 8, 2023
Merged

Cross-build for JS+Native #409

merged 7 commits into from
Jun 8, 2023

Conversation

armanbilge
Copy link
Member

Almost there, just have to track down a couple things ... :)

@armanbilge
Copy link
Member Author

armanbilge commented Jun 6, 2023

Darn.

Update: Miles and I chatted on Discord, it seems that skunk-circe is not being used in the failing test. So there's something else going on 🤔

@armanbilge armanbilge marked this pull request as ready for review June 7, 2023 14:46
Copy link
Member Author

@armanbilge armanbilge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Had to move some tests to js-jvm only sources. I'll circle back when the next wave of Scala Native improvements release. We should be able to make this project 100% shared code.

assert(weaklyEqual(x, y, strictPaths))
assert(weaklyEqual(clue(x), clue(y), strictPaths))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Anything wrapped in clue will be printed when the assertion fails, useful for debugging.

Comment on lines +1562 to +1563
// JS treats floats as doubles
def isJS = Option(System.getProperty("java.vm.name")).contains("Scala.js")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was highly annoying but does the trick ...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ouch, but 👍

@armanbilge armanbilge requested a review from milessabin June 7, 2023 14:49
@armanbilge armanbilge linked an issue Jun 7, 2023 that may be closed by this pull request
Copy link
Member

@milessabin milessabin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome! Thanks so much 🎉

@@ -26,7 +25,7 @@ trait SqlDatabaseSuite extends CatsEffectSuite {
}

def bindPath(path: String): String =
Path(".").absolute.parent.flatMap(_.parent).flatMap(_.parent).get.toString+"/"+path
buildinfo.BuildInfo.baseDirectory + "/" + path
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is much better ... thanks!

Comment on lines +1562 to +1563
// JS treats floats as doubles
def isJS = Option(System.getProperty("java.vm.name")).contains("Scala.js")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ouch, but 👍

@milessabin milessabin merged commit aa3c734 into main Jun 8, 2023
@armanbilge armanbilge deleted the pr/js-native branch June 8, 2023 12:48
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.

Cross-build for Scala.js
2 participants