Commit 919eefc
Request can be created and sent via a message with an expiration date that has passed (#369)
* chore: respect expireation date of request when creating request and sending message
* chore: white space
* Update packages/consumption/test/modules/requests/OutgoingRequestsController.test.ts
Co-authored-by: Julian König <33655937+jkoenig134@users.noreply.github.com>
* Update packages/consumption/src/consumption/ConsumptionCoreErrors.ts
Co-authored-by: Milena Czierlinski <146972016+Milena-Czierlinski@users.noreply.github.com>
* chore: fix test misstake
* chore: fix tests
* chore: PR comments
* chore: revert Date changes
* chore: pr comments
* chore: test
* chore: fix flaky test
* Update packages/consumption/test/modules/requests/OutgoingRequestsController.test.ts
Co-authored-by: Milena Czierlinski <146972016+Milena-Czierlinski@users.noreply.github.com>
* Update packages/consumption/test/modules/requests/OutgoingRequestsController.test.ts
Co-authored-by: Milena Czierlinski <146972016+Milena-Czierlinski@users.noreply.github.com>
* chore: improve test performance
* chore: improve test performance
* chore: PR comments
* refactor: add empty lines
* Uniqueness of `key` for RelationshipAttributes (#319)
* refactor: preapare CreateAttributeRequestItemProcessor to add more validation
* feat: add validation for CreateAttributeRequestItemProcessor
* test: CreateAttributeRequestItemProcessor key validation
* fix: uniqueness for key only instead of pair of owner and key
* fix: failing test
* test: ensure key uniqueness in attributes.test
* test: ensure key uniqueness in CreateRelationshipAttributeRequestItemDVO.test
* feat: use database language every database understands
* test: ensure key uniqueness only for constant ownership
* fix: too late clean up of Attributes
* feat: ensure key uniqueness only for RelationshipAttributes that are not in deletion in any way
* refactor: extract function call as auxiliary function
* refactor: put afterEach block inside describe block
* feat: ensure key uniqueness for Recipient within CreateAttributeRequestItemProcessor
* refactor: auxiliary function can be applied to queries as well
* feat: ensure key uniqueness for Sender within ReadAttributeRequestItemProcessor
* feat: ensure key uniqueness only for constant value type
* fix: failing tests with async canCreateOutgoingRequestItem method
* feat: key uniqueness for Recipient within ReadAttributeRequestItemProcessor
* feat: ensure key uniquess for empty owner as placeholder as well
* refactor: simplify error message
* refactor: move validation to canAccept method
* refactor: standardize error messages
* test: ensure key uniqueness with empty owner
* test: move tests to canAccept block
* fix: call accept instead of canAccept
* test: refactor canAccept test with SuccessfulValidationResult
* test: make tests independent of each other
* feat: ensure key uniqueness for empty owner queried with ReadAttributeRequestItem
* feat: ensure key uniqueness on Sender site of ProposeAttributeRequestItemProcessor
* feat: ensure key uniqueness on Recipient site of ProposeAttributeRequestItemProcessor
* refactor: standardize error messages
* feat: prohibit Requests that create more than one RelationshipAttribute with same key
* fix: title type
* test: key uniqueness of incomingRequestsController
* test: key uniqueness of OutgoingRequestsController
* refactor: remove recursion of IncomingRequestsController
* refactor: keep RequestItemGroup in mind
* refactor: use auxiliary method for clearness
* feat: handle empty owner in IncomingRequestsController and OutgoingRequestsController
* test: ensure key uniqueness for empty owner
* refactor: move validation from canDecide to canAccept
* fix: failing IncomingRequestsController test
* test: ensure key uniqueness with RequestItemGroups
* fix: wrong DecideRequestParameters for RequestItemGroups
* feat: use already known separation sequence
* feat: give better validation function name
* refactor: do not break existing code blocks anymore
* fix: error due to incorrect merging
* test: ensure key uniqueness with ProposeAttributeRequestItem
* chore: descriptive values should not start with capital letter
* refactor: rename error code
* feat: distinguish between user mistake and deformed Request
* feat: throwing instead of returning error if Request is deformed
* feat: reuse key uniqueness error
* feat: distinguish between deformed Requests and wrong accept parameters
* test: RequestItem cannot be accepted due to incorrect params of User
* fix: failing test due to void return
* feat: self-explanatory variable names
* refactor: more renaming of variables
* refactor: unify renaming
* feat: simplify error message for unknown recipient of Request
* feat: incorporate some review comments
* fix: failing test due to wrong error format
* feat: incorporate review comment
* refactor: prepare reusability of code
* fix: error due to merge
* feat: use JSON.stringify() instead of own method for extracting identifiers
* refactor: reduce redundancy by move auxiliary functions to different file
* feat: inform user what key would be redundantly in use
* feat: incorporate some review comments
* feat: incoporate review comments
* refactor: change order of thrown errors
* test: can propose and query RelationshipAttribute with same key but different value type
* feat: incorporate review comments
* refactor: simplify extraction of fragments of mustBeAcceptedItems
* refactor: further simplification of extraction of fragments of mustBeAcceptedItems
* refactor: simplify extraction of fragments of accepte items
* fix: returned instead of continued
* test: RequestItem cannot be accepted if key uniqueness is violated regardless of value of mustBeAccepted
---------
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Milena Czierlinski <milena.czierlinski@js-soft.com>
* chore: prettier
* chore: pr comments
---------
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Julian König <33655937+jkoenig134@users.noreply.github.com>
Co-authored-by: Milena Czierlinski <146972016+Milena-Czierlinski@users.noreply.github.com>
Co-authored-by: Milena Czierlinski <milena.czierlinski@js-soft.com>
Co-authored-by: Britta Stallknecht <146106656+britsta@users.noreply.github.com>1 parent 6bd9be2 commit 919eefc
File tree
6 files changed
+106
-7
lines changed- packages
- consumption
- src
- consumption
- modules/requests/outgoing
- test/modules/requests
- runtime
- src/useCases
- common
- transport/messages
- test/transport
6 files changed
+106
-7
lines changedLines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
336 | 336 | | |
337 | 337 | | |
338 | 338 | | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
339 | 343 | | |
340 | 344 | | |
341 | 345 | | |
| |||
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
49 | 53 | | |
50 | 54 | | |
51 | 55 | | |
| |||
Lines changed: 28 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
231 | 231 | | |
232 | 232 | | |
233 | 233 | | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
234 | 252 | | |
235 | 253 | | |
236 | 254 | | |
| |||
745 | 763 | | |
746 | 764 | | |
747 | 765 | | |
748 | | - | |
| 766 | + | |
749 | 767 | | |
750 | 768 | | |
751 | 769 | | |
| 770 | + | |
752 | 771 | | |
753 | 772 | | |
754 | 773 | | |
755 | 774 | | |
756 | 775 | | |
757 | 776 | | |
758 | | - | |
759 | 777 | | |
760 | 778 | | |
761 | 779 | | |
762 | | - | |
| 780 | + | |
763 | 781 | | |
764 | 782 | | |
765 | 783 | | |
| 784 | + | |
766 | 785 | | |
| 786 | + | |
767 | 787 | | |
768 | 788 | | |
769 | 789 | | |
| |||
784 | 804 | | |
785 | 805 | | |
786 | 806 | | |
787 | | - | |
| 807 | + | |
788 | 808 | | |
789 | 809 | | |
790 | 810 | | |
| 811 | + | |
791 | 812 | | |
792 | 813 | | |
793 | 814 | | |
| |||
863 | 884 | | |
864 | 885 | | |
865 | 886 | | |
866 | | - | |
| 887 | + | |
867 | 888 | | |
868 | 889 | | |
869 | 890 | | |
| 891 | + | |
870 | 892 | | |
871 | 893 | | |
872 | 894 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
128 | 128 | | |
129 | 129 | | |
130 | 130 | | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
131 | 138 | | |
132 | 139 | | |
133 | 140 | | |
| |||
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
146 | 150 | | |
147 | 151 | | |
148 | 152 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
1 | 2 | | |
2 | 3 | | |
3 | 4 | | |
| |||
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| 10 | + | |
9 | 11 | | |
10 | 12 | | |
| 13 | + | |
11 | 14 | | |
12 | 15 | | |
13 | 16 | | |
| |||
272 | 275 | | |
273 | 276 | | |
274 | 277 | | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
275 | 333 | | |
276 | 334 | | |
277 | 335 | | |
| |||
0 commit comments