This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| local ffi = require "ffi" | |
| ffi.cdef[[ | |
| void* malloc(size_t size); | |
| void* realloc (void* ptr, size_t size); | |
| void* calloc(size_t num, size_t size); | |
| void free(void* ptr); | |
| typedef struct _MATRIX4_ { | |
| double* data; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Brick(carryCapacity) { | |
| this.carryCapacity = carryCapacity; | |
| // carry function | |
| this.carry = function(weight) { | |
| if(weight < this.carryCapacity) { | |
| return true; | |
| } else { | |
| return false; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function BuildHouse() { | |
| LayFoundation(); | |
| Frame(); | |
| RunPlumbing(); | |
| RunElectrical(); | |
| Insulate(); | |
| FinishDetails(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const { expect } = require('chai'); | |
| const Brick = require('./brick'); // Adjust the path based on your file structure | |
| describe('Brick', () => { | |
| describe('carry function', () => { | |
| it('should return true if weight is below carry capacity', () => { | |
| const brick = new Brick(10); | |
| const result = brick.carry(8); | |
| expect(result).to.be.true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const { expect } = require('chai'); | |
| const sinon = require('sinon'); | |
| // Import the functions that are called inside BuildHouse | |
| const { | |
| LayFoundation, | |
| Frame, | |
| RunPlumbing, | |
| RunElectrical, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const axios = require('axios'); | |
| const { expect } = require('chai'); | |
| describe('API Contract Test', () => { | |
| it('should return an object with name and age given GUID and security code', async () => { | |
| // Mock data for the request | |
| const requestData = { | |
| guid: 'some-guid', | |
| securityCode: '123456' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 16:22:52.835 973 1487 I MRSS : MIXEDREALITY: MrServiceModelBase: ClientStats: com.oculus.guardian, VrMode: 1, PT: 1, FS: 0, Depth: 0, Layers: 1 (active: 1 compositor: 1), Rec PT : 1, Proj PT: 0, BG PT : 0, KH PT : 0, Shaders: 1 | |
| 16:22:52.874 3297 10349 W AppManagerInternal: Entitlement for packageName=com.oculus.os.cm not found in cache, channels=[Store, Q4B] | |
| 16:22:52.874 5353 6246 W OVRLibrary : null cursor received for query content://com.oculus.ocms.library/apps/com.android.networkstack.tethering.inprocess | |
| 16:22:52.876 5353 18082 W OVRLibrary : null cursor received for query content://com.oculus.ocms.library/apps/com.oculus.os.cm | |
| 16:22:52.913 973 1513 I MRSS : BOLT:HexagonTelemetry: Global DSP utilization: 29.22% (1462 / 5003 ms), Scalar Util: 64.49%, HVX Util: 54.23%, HMX Util: 23.24%, DMA Active: 0.00%, Freq: 787.2 MHz | |
| 16:22:52.913 973 1513 I MRSS : boltlib: Invoking logging callbacks. onAbort=false | |
| 16:22:52.913 973 1513 I MRSS : boltlib: Loaded |