musora-content-services 1.0.206 → 1.0.208
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/docs/config.js.html +2 -2
- package/docs/index.html +2 -2
- package/docs/module-Config.html +2 -2
- package/docs/module-Railcontent-Services.html +1703 -866
- package/docs/module-Sanity-Services.html +682 -48
- package/docs/railcontent.js.html +88 -7
- package/docs/sanity.js.html +217 -36
- package/link_mcs.sh +0 -0
- package/package.json +1 -1
- package/src/contentMetaData.js +0 -0
- package/src/filterBuilder.js +1 -2
- package/src/index.d.ts +2 -0
- package/src/index.js +2 -0
- package/src/services/contentProgress.js +0 -0
- package/src/services/dataContext.js +0 -0
- package/src/services/railcontent.js +13 -0
- package/src/services/sanity.js +1 -1
- package/test/contentProgress.test.js +0 -0
- package/test/live/contentProgressLive.test.js +0 -0
- package/test/live/railcontentLive.test.js +0 -0
- package/test/sanityQueryService.test.js +7 -6
|
File without changes
|
|
@@ -747,7 +747,8 @@ describe('Filter Builder', function () {
|
|
|
747
747
|
const filter = 'railcontent_id = 111'
|
|
748
748
|
const builder = new FilterBuilder(filter,
|
|
749
749
|
{
|
|
750
|
-
bypassPermissions: true
|
|
750
|
+
bypassPermissions: true,
|
|
751
|
+
pullFutureContent: false
|
|
751
752
|
});
|
|
752
753
|
const finalFilter = await builder.buildFilter();
|
|
753
754
|
const expected = "references(*[_type == 'permission' && railcontent_id in [78,91,92]]._id)"
|
|
@@ -775,11 +776,11 @@ describe('Filter Builder', function () {
|
|
|
775
776
|
expect(clauses[0].phrase).toBe(filter);
|
|
776
777
|
expect(clauses[1].field).toBe('status');
|
|
777
778
|
expect(clauses[1].operator).toBe('in');
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
779
|
+
// expect(clauses[2].field).toBe('published_on');
|
|
780
|
+
// expect(clauses[2].operator).toBe('<=');
|
|
781
|
+
// const restrictionDate = new Date(clauses[2].condition)
|
|
782
|
+
// const now = new Date();
|
|
783
|
+
// expect(now.getTime()).toBeLessThan(restrictionDate.getTime());
|
|
783
784
|
|
|
784
785
|
builder = new FilterBuilder(filter,
|
|
785
786
|
{
|