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

Added new methods to builder (#748) #752

Merged
merged 5 commits into from
Jul 19, 2022
Merged

Added new methods to builder (#748) #752

merged 5 commits into from
Jul 19, 2022

Conversation

maicol07
Copy link
Contributor

@maicol07 maicol07 commented Jul 8, 2022

The following methods have been implemented from #748:

  • unsigned_big_integer
  • id
  • foreign_id
  • foreign_id_for
  • foreign_uuid

@josephmancuso
Copy link
Member

Just have to fix the tests

@maicol07
Copy link
Contributor Author

maicol07 commented Jul 9, 2022

@josephmancuso should be fixed!

@maicol07
Copy link
Contributor Author

This time they're fixed for good!

@josephmancuso
Copy link
Member

I don't see a test for the foreign_id_for one. Just need to make sure the model name and primary key is correctly formed.

More tests the better. Allows me to make changes with comfort

@maicol07
Copy link
Contributor Author

How can I create a Model in tests? Should I just have to create a new model instance?

@josephmancuso
Copy link
Member

Yup just make a model as you normally would inside the test file and use it.

Example: https://github.com/MasoniteFramework/orm/blob/2.0/tests/mysql/relationships/test_belongs_to_many.py#L16-L23

@maicol07
Copy link
Contributor Author

@josephmancuso done!

@josephmancuso josephmancuso merged commit 8cfc1c8 into MasoniteFramework:2.0 Jul 19, 2022
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.

2 participants