How to use the github.com/org/a function in github

To help you get started, we’ve selected a few github examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github uber-archive / idl / test / idl.js View on Github external
);

        assert.equal(
            data[3].local.idl['meta.json'].version,
            now + 2000,
            'Correct meta.json version'
        );

        assert.equal(
            data[3].local.idl['meta.json'].remotes['github.com/org/b'].time,
            (new Date(now + 2000)).toISOString(),
            'Correct version of B'
        );

        assert.equal(
            data[3].local.idl['meta.json'].remotes['github.com/org/a'].time,
            (new Date(now + 1000)).toISOString(),
            'Correct version of A'
        );

        // Remote A and B updated and published. Update run.
        assert.equal(
            data[8].local.idl['github.com'].org.a['service.thrift'],
            template(updatedThriftIdlTemplate, { remoteName: 'A' }),
            'Correct thrift A file locally'
        );

        assert.equal(
            data[8].local.idl['github.com'].org.b['service.thrift'],
            template(updatedThriftIdlTemplate, { remoteName: 'B' }),
            'Correct thrift B file locally'
        );
github uber-archive / idl / test / idl-daemon.js View on Github external
assert.equal(
            data.files['idl/github.com/org/c/service.thrift'],
            thriftIdl('C'),
            'Correct thrift definition for C'
        );

        assert.equal(
            data.files['idl/github.com/org/d/service.thrift'],
            thriftIdl('D'),
            'Correct thrift definition for D'
        );

        var remotes = data.meta.remotes;
        var tags = data.gittag.trim().split('\n');

        assert.equal(tags[0], 'v' + new Date(remotes['github.com/org/a'].time)
            .getTime());
        assert.equal(tags[2], 'v' + new Date(remotes['github.com/org/c'].time)
            .getTime());
        assert.equal(tags[3], 'v' + new Date(remotes['github.com/org/d'].time)
            .getTime());
        assert.equal(tags[4], 'v' + new Date(remotes['github.com/org/b'].time)
            .getTime());

        assert.end();
    }
});
github uber-archive / idl / test / idl.js View on Github external
);

        assert.equal(
            data[8].local.idl['meta.json'].version,
            now + 8000,
            'Correct meta.json version'
        );

        assert.equal(
            data[8].local.idl['meta.json'].remotes['github.com/org/b'].time,
            (new Date(now + 8000)).toISOString(),
            'Correct version of B'
        );

        assert.equal(
            data[8].local.idl['meta.json'].remotes['github.com/org/a'].time,
            (new Date(now + 6000)).toISOString(),
            'Correct version of A'
        );

        tk.reset();
        assert.end();
    }
});
github uber-archive / idl / test / thrift-store.js View on Github external
list.remotes['github.com/org/b'].time
        );
        assert.equal(
            upstream.meta.remotes['github.com/org/c'].time,
            list.remotes['github.com/org/c'].time
        );
        assert.equal(
            upstream.meta.remotes['github.com/org/d'].time,
            list.remotes['github.com/org/d'].time
        );

        var text = list.toString();

        assert.equal(
            text,
            ' - github.com/org/a  ' + upstream.meta.remotes['github.com/org/a']
                .time + '\n' +
            ' - github.com/org/b  ' + upstream.meta.remotes['github.com/org/b']
                .time + '\n' +
            ' - github.com/org/c  ' + upstream.meta.remotes['github.com/org/c']
                .time + '\n' +
            ' - github.com/org/d  ' + upstream.meta.remotes['github.com/org/d']
                .time
        );

        assert.end();
    }
});
github uber-archive / idl / test / idl-daemon.js View on Github external
assert.equal(data.gitlog,
            'Updating D to latest version\n' +
            'Updating C to latest version\n' +
            'Updating B to latest version\n' +
            'Updating A to latest version\n' +
            'initial\n'
        );

        assert.equal(data.meta.time,
            data.meta.remotes['github.com/org/d'].time);
        assert.equal(new Date(data.meta.time).getTime(),
            data.meta.version);

        assert.deepEqual(
            data.meta.remotes['github.com/org/a'].shasums,
            {
                'service.thrift': 'd329c8c24d0871076a5f05180a439bccb9bebe71'
            },
            'Correct shasums for remote A'
        );
        assert.deepEqual(
            data.meta.remotes['github.com/org/b'].shasums,
            {
                'service.thrift': '424a6ca9b4660bf432045eeba7a3254ab38d5701'
            },
            'Correct shasums for remote B'
        );
        assert.deepEqual(
            data.meta.remotes['github.com/org/c'].shasums,
            {
                'service.thrift': '484742978a072e46ae1131d8efe7fe0377d35c54'
github uber-archive / idl / test / thrift-store.js View on Github external
function onResults(err, data) {
        if (err) {
            assert.ifError(err);
        }

        var list = data.list;
        var upstream = data.upstream;

        assert.equal(
            upstream.meta.remotes['github.com/org/a'].time,
            list.remotes['github.com/org/a'].time
        );
        assert.equal(
            upstream.meta.remotes['github.com/org/b'].time,
            list.remotes['github.com/org/b'].time
        );
        assert.equal(
            upstream.meta.remotes['github.com/org/c'].time,
            list.remotes['github.com/org/c'].time
        );
        assert.equal(
            upstream.meta.remotes['github.com/org/d'].time,
            list.remotes['github.com/org/d'].time
        );

        var text = list.toString();
github uber-archive / idl / test / idl-daemon.js View on Github external
'Correct git log contents'
        );

        assert.equal(
            data.meta.time,
            data.meta.remotes['github.com/org/d'].time,
            'Correct timestamp on last update'
        );
        assert.equal(
            new Date(data.meta.time).getTime(),
            data.meta.version,
            'Version is correct and is a timestamp'
        );

        assert.deepEqual(
            data.meta.remotes['github.com/org/a'].shasums,
            {
                'service.thrift': 'd329c8c24d0871076a5f05180a439bccb9bebe71'
            },
            'Correct shasums for remote A'
        );
        assert.deepEqual(
            data.meta.remotes['github.com/org/b'].shasums,
            {
                'service.thrift': '424a6ca9b4660bf432045eeba7a3254ab38d5701'
            },
            'Correct shasums for remote B'
        );
        assert.deepEqual(
            data.meta.remotes['github.com/org/c'].shasums,
            {
                'service.thrift': '484742978a072e46ae1131d8efe7fe0377d35c54'