Comments (5)
I am new to go as well as go-github project. I am trying to set up the go repository and was able to run the basicauth example. How are the tests set up? I am unable to test the individual test files here. I am running these tests locally.
from go-github.
the go repository
What repository exactly?
How are the tests set up? I am unable to test the individual test files here. I am running these tests locally.
The go-github project uses standard Go tests. They're inside the github.com/google/go-github/github
package, so running go test github.com/google/go-github/github
would run all the tests there.
I am new to go as well as go-github project.
Please see here for the best places to ask Go questions:
https://github.com/golang/go/wiki/Questions
from go-github.
I am sorry for spelling out the repository wrong. I am using the go-github repository.
After cloning the repository, i tried running the integration test cases in the tests/integration folder with GITHUB_AUTH_TOKEN set in environment.
Here is what I did from the GitHub folder
go get -t -v ./...
go test -v ../tests/integration/*
Here is the error I got
../tests/integration/repos_test.go:117: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:121: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:122: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:123: unknown github.RequiredStatusChecks field 'EnforcementLevel' in struct literal
../tests/integration/repos_test.go:126: client.Repositories.EditBranch undefined (type *github.RepositoriesService has no field or method EditBranch)
../tests/integration/repos_test.go:131: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:134: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:135: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:139: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:140: branch.Protection undefined (type *github.Branch has no field or method Protection)
../tests/integration/repos_test.go:140: too many errors
FAIL command-line-arguments [build failed]
Is the integration folder broken, can i raise an issue and try to solve?
All the tests in the GitHub folder of the go-github project passes. it is only the integration files that seem to be broken.
from go-github.
I am sorry for spelling out the repository wrong. I am using the go-github repository.
No problem, I just wanted to make sure I'm not misunderstanding you.
Is the integration folder broken, can i raise an issue and try to solve?
Yes, it is, I got the same errors. Please do. Open a new issue, and feel free to work on a PR to resolve it. The integration tests are run manually, so they got out of date after some breaking API changes in the library. Thanks!
By the way, don't forget to read over the integration tests README. You should run them with -tags=integration
, instead of specifying individual .go
files via *
.
(Also, feel free to review PR #506 since it's related.)
from go-github.
Possibly related to: #310 (comment)
from go-github.
Related Issues (20)
- Update deprecated endpoints in github/action_variables.go HOT 4
- `omitempty` tag on `InstallationAccessTokenOptions.Repositories` masking functionality of GitHub API HOT 11
- `NewTeam` missing `notification_setting` field HOT 1
- feat: Add an option to wait for primary rate limit reset and retry instead of erroring out HOT 7
- Username is required when using fine-grained vs classic PAT (personal access token) for PlainClone operation
- LIst of issue comments do not collect the comment which was added during the creation of the PR. HOT 6
- Use enums for the action field in GitHub Webhooks HOT 4
- Can't remove repository ruleset's every Bypass Actors because of serialization issue HOT 4
- Support new REST API endpoint that evaluates if private vulnerability reporting is enabled HOT 4
- Webhook MemberEvent Type is Missing Changes Object
- Bug: Issues.ListByRepo Repository field is always `nil` HOT 5
- `ListRunnersOption` change omits consideration of Enterprise Runner HOT 4
- Add support for CommitID, InReplyTo, and SubjectType to DraftReviewComment HOT 1
- Support for merge queues. HOT 3
- Bug: GetArchiveLink returns a status code 200, not 302, when link is requested with an installation token rather than personal/bearer token HOT 3
- WorkflowRun struct does not include `path` property HOT 1
- Proposal: Add GitHub App Token and Installation Token Source Functionality HOT 6
- GetEnterpriseRunner method appears to be missing HOT 1
- RepositoryPermissionLevel is missing role_name
- Space being stripped from Workflow Run, Job, and Step Names HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from go-github.